Sha256: 73674e040fd1c97ff35f1861572bce6263362919bb079229b8324ac91c916100

Contents?: true

Size: 737 Bytes

Versions: 2

Compression:

Stored size: 737 Bytes

Contents

module Rsense
  module Server
    module Command
      module Preload

        def stub_data(path)
          filepath = path.join("/lib/code.rb")
          {
            "command"=>"code_completion",
            "project" => path.to_s,
            "file" =>  filepath.to_s,
            "code" => "def check(testarg)\n  testarg\nend\ncheck('hello')",
            "location" => { "row" => 2, "column" => 10 }
          }
        end
        module_function :stub_data

        def load(project_manager, path)
          PROJMAN.roptions = Rsense::Server::Options.new(stub_data(path))
          PROJMAN.rcommand = Rsense::Server::Command::Command.new(PROJMAN.roptions)
        end

        module_function :load

      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rsense-server-0.5.10 lib/rsense/server/command/preload.rb
rsense-server-0.5.9 lib/rsense/server/command/preload.rb