Class: Matchi::BeFalse
- Inherits:
-
Object
- Object
- Matchi::BeFalse
- Defined in:
- lib/matchi/be_false.rb
Overview
Untruth matcher.
Instance Method Summary collapse
-
#matches? ⇒ Boolean
Boolean comparison between the actual value and the expected value.
-
#to_h ⇒ Hash
Returns a hash of one key-value pair with a key corresponding to the matcher and a value corresponding to its initialize parameters.
-
#to_s ⇒ String
Returns a string representing the matcher.
Instance Method Details
#matches? ⇒ Boolean
Boolean comparison between the actual value and the expected value.
13 14 15 |
# File 'lib/matchi/be_false.rb', line 13 def matches? false.equal?(yield) end |
#to_h ⇒ Hash
Returns a hash of one key-value pair with a key corresponding to the
matcher and a value corresponding to its initialize parameters.
36 37 38 |
# File 'lib/matchi/be_false.rb', line 36 def to_h { BeFalse: [] } end |
#to_s ⇒ String
Returns a string representing the matcher.
24 25 26 |
# File 'lib/matchi/be_false.rb', line 24 def to_s 'be_false' end |