Sha256: ff004457f704f2fd5bec09701d18a3b92af5c83275341b798eb7bc0caa85a027

Contents?: true

Size: 1.34 KB

Versions: 15

Compression:

Stored size: 1.34 KB

Contents

require File.join(File.dirname(__FILE__),'..','spec_helper')
require File.join(File.dirname(__FILE__),'..','..','lib','rhoconnect','server.rb')

describe "Rhoconnect::RhoInternalJsBenchAdapter" do
  include Rhoconnect
  include_examples "SharedRhoconnectHelper", :rhoconnect_data => true

  before(:each) do
    Rhoconnect::Server.set :environment, :test
    Rhoconnect::Server.set :secret, "secure!"
    Rhoconnect.use_node = true
    Rhoconnect.bootstrap(get_testapp_path)
  end

  def app
    @app ||= Rack::URLMap.new Rhoconnect.url_map
  end

  after(:each) do
    Rhoconnect::Store.flush_all
    Rhoconnect::Node.kill_process
    #Source.valid_doctypes.delete('tmpdoc'.to_sym)
  end

  it "should call login method from model" do
    rho_int = RhoInternalJsBenchAdapter.new(Source.load('RhoInternalJsBenchAdapter', {:app_id => @a.id, :user_id => @u.id}))
    res = rho_int.login
    res.should == true
  end

  it "should call logoff method from model" do
    rho_int = RhoInternalJsBenchAdapter.new(Source.load('RhoInternalJsBenchAdapter', {:app_id => @a.id, :user_id => @u.id}))
    res = rho_int.logoff
    res.should == true
  end

  it "should call query method from model" do
    rho_int = RhoInternalJsBenchAdapter.new(Source.load('RhoInternalJsBenchAdapter', {:app_id => @a.id, :user_id => @u.id}))
    res = rho_int.query
    res.should == true
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
rhoconnect-7.6.0 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-7.5.1 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-7.4.1 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-7.1.17 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-6.2.0 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-6.0.11 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.18 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.17 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.15 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.0.22 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.2 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.0.7 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.0.3 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.5.0 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb
rhoconnect-5.1.1 spec/predefined_adapters/rho_internal_js_bench_adapter_js_spec.rb