Module: MiniTestPredicates::Spec
- Defined in:
- lib/minitest-predicates/core.rb
Instance Method Summary collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args) ⇒ Object
72 73 74 75 76 77 78 79 |
# File 'lib/minitest-predicates/core.rb', line 72 def method_missing name, *args result = MiniTestPredicates.make_assertion! :name => name, :object => self, :args => args, :positive => [/^must_be_(.+)$/, /^must_(.+)$/], :negative => [/^wont_be_(.+)$/, /^wont_(.+)$/] result == :super ? super : result end |