Skip to content
This repository has been archived by the owner on Jul 20, 2021. It is now read-only.

Commit

Permalink
solve deprecation warning
Browse files Browse the repository at this point in the history
  • Loading branch information
tkrajcar committed Mar 21, 2014
1 parent 59290fa commit b4ab67c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion spec/unit/core/connection/connection_state_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@
it 'implements #handle_input' do
expect {
subject.handle_input('Hello World!')
}.not_to raise_error(NotImplementedError)
}.not_to raise_error

This comment has been minimized.

Copy link
@openmailbox

openmailbox Mar 21, 2014

Collaborator

I really hate this. It changes the intent of the spec, which is to make sure the implementing class actually implements the method. If that implementation raises another kind of exception, I don't care. If they are really deprecating this in new RSpec, I feel like there has to be an alternative somewhere.

end
end

1 comment on commit b4ab67c

@tkrajcar
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't disagree. It seems to be an issue with how RSpec internally raises exceptions. Relevant discussion: rspec/rspec-expectations#231

Specifically, rspec/rspec-expectations#231 (comment) has a good idea of whipping together a quick custom RSpec matcher.

Please sign in to comment.