Class: TestEqualityWithLCS::Spec::BeEqualWithLCS
- Inherits:
-
Object
- Object
- TestEqualityWithLCS::Spec::BeEqualWithLCS
- Includes:
- TestEqualityWithLCS::SharedMethods
- Defined in:
- lib/test_equality_with_lcs/spec.rb
Instance Method Summary collapse
- #failure_message_for_should ⇒ Object
- #failure_message_for_should_not ⇒ Object
-
#initialize(expected) ⇒ BeEqualWithLCS
constructor
A new instance of BeEqualWithLCS.
- #matches?(target) ⇒ Boolean
Methods included from TestEqualityWithLCS::SharedMethods
Constructor Details
#initialize(expected) ⇒ BeEqualWithLCS
Returns a new instance of BeEqualWithLCS.
6 7 8 |
# File 'lib/test_equality_with_lcs/spec.rb', line 6 def initialize expected @expected = expected end |
Instance Method Details
#failure_message_for_should ⇒ Object
15 16 17 |
# File 'lib/test_equality_with_lcs/spec.rb', line 15 def @expected, @target end |
#failure_message_for_should_not ⇒ Object
19 20 21 |
# File 'lib/test_equality_with_lcs/spec.rb', line 19 def @expected, @target end |
#matches?(target) ⇒ Boolean
10 11 12 13 |
# File 'lib/test_equality_with_lcs/spec.rb', line 10 def matches? target @target = target @expected == @target end |