lib/submodules/ably-ruby/spec/acceptance/realtime/auth_spec.rb in ably-rest-1.1.2 vs lib/submodules/ably-ruby/spec/acceptance/realtime/auth_spec.rb in ably-rest-1.1.3
- old
+ new
@@ -1056,11 +1056,11 @@
context 'when credentials are wrong' do
let(:auth_params) { { keyName: key_name, keySecret: 'invalid' } }
it 'disconnected includes and invalid signature message' do
client.connection.once(:disconnected) do |state_change|
- expect(state_change.reason.message.match(/invalid signature/i)).to_not be_nil
+ expect(state_change.reason.message.match(/signature verification failed/i)).to_not be_nil
expect(state_change.reason.code).to eql(40144)
stop_reactor
end
client.connect
end
@@ -1109,11 +1109,11 @@
context 'when credentials are invalid' do
let(:auth_params) { { keyName: key_name, keySecret: 'invalid' } }
it 'authentication fails and reason for disconnection is invalid signature' do
client.connection.once(:disconnected) do |state_change|
- expect(state_change.reason.message.match(/invalid signature/i)).to_not be_nil
+ expect(state_change.reason.message.match(/signature verification failed/i)).to_not be_nil
expect(state_change.reason.code).to eql(40144)
stop_reactor
end
client.connect
end
@@ -1141,10 +1141,10 @@
let(:token) { Faraday.get("#{auth_url}?keyName=#{key_name}&keySecret=#{key_secret}").body }
let(:client_options) { { token: token, environment: environment, protocol: protocol, log_level: :none } }
it 'fails with an invalid signature error' do
client.connection.once(:disconnected) do |state_change|
- expect(state_change.reason.message.match(/invalid signature/i)).to_not be_nil
+ expect(state_change.reason.message.match(/signature verification failed/i)).to_not be_nil
expect(state_change.reason.code).to eql(40144)
stop_reactor
end
client.connect
end