1
0
Fork 0
mirror of https://github.com/thoughtbot/shoulda-matchers.git synced 2022-11-09 12:01:38 -05:00
thoughtbot--shoulda-matchers/spec/support/unit/shared_examples/numerical_submatcher.rb
Elliot Winkler bbdf8a807e Reorganize unit tests, part I
* Move spec/shoulda to spec/unit_tests/shoulda
* Move spec/support/*.rb to spec/support/unit_tests/{helpers,matchers}
* Move spec_helper.rb to unit_spec_helper.rb
2014-11-04 14:43:59 -07:00

17 lines
553 B
Ruby

shared_examples 'a numerical submatcher' do
it 'implements the with_message method' do
expect(subject).to respond_to(:with_message).with(1).arguments
end
it 'implements the matches? method' do
expect(subject).to respond_to(:matches?).with(1).arguments
end
it 'implements the failure_message method' do
expect(subject).to respond_to(:failure_message).with(0).arguments
end
it 'implements the failure_message_when_negated method' do
expect(subject).to respond_to(:failure_message_when_negated).with(0).arguments
end
end