spec/netsuite/configuration_spec.rb in netsuite-0.9.2 vs spec/netsuite/configuration_spec.rb in netsuite-0.9.3

- old
+ new

@@ -517,16 +517,24 @@ describe '#proxy' do it 'defaults to nil' do expect(config.proxy).to be_nil end + it 'does not pass in nil proxy to savon' do + connection = config.connection + + expect(connection.globals.include?(:proxy)).to eql(false) + end + it 'can be set with proxy=' do config.proxy = "https://my-proxy" expect(config.proxy).to eql("https://my-proxy") # ensure no exception is raised - config.connection + connection = config.connection + + expect(connection.globals.include?(:proxy)).to eql(true) end it 'can be set with proxy(value)' do config.proxy("https://my-proxy")