Sha256: d915a601be0c96492bcacabc335ba2530fa44fba51178f6702b9f0e514abce7e

Contents?: true

Size: 1.29 KB

Versions: 2

Compression:

Stored size: 1.29 KB

Contents

require File.expand_path(File.dirname(__FILE__) + '../../spec_helper')

describe "Client class" do
  before(:all) do
    Muhimbi::Config.setup do |config|
      config.wsdl = config_options["wsdl"]
      config.timeout = config_options["timeout"]
    end
    @client = Muhimbi::Client.client
  end

  it "savon client" do
    @client.class.should == Savon::Client
  end

  it "timeout should configurable" do
    @client.instance_variable_get("@wsdl").request.open_timeout.should == config_options["timeout"]
    @client.instance_variable_get("@wsdl").request.read_timeout.should == config_options["timeout"]
  end

  it "should have operations" do
    @client.operations.class.should == Array
  end

  it "operations should include to convert" do
    @client.operations.include?(:convert).should be_true
  end

   context "Get Configuration" do
     before :each do
       @client = Muhimbi::Client
     end
     it "get_configuration" do
       @client.get_configuration.should_not be_blank
       @client.get_configuration.keys.should include(:conversion_server_address)
     end
   end

   context "Get Diagnostics" do
     before :each do
       @client = Muhimbi::Client
     end
     it "get_diagnostics" do
       @client.get_diagnostics(["WordProcessing", "InfoPath"]).should_not be_blank
     end
   end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
muhimbi-0.0.5 spec/functional/client_spec.rb
muhimbi-0.0.4 spec/functional/client_spec.rb