Module: Speccify::ExampleGroupMethods
- Defined in:
- lib/speccify.rb
Overview
ExampleGroupClassMethods
Instance Method Summary collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args, &block) ⇒ Object
57 58 59 60 61 62 63 64 65 |
# File 'lib/speccify.rb', line 57 def method_missing(name, *args, &block) if (name.to_s =~ /^be_(.+)/) Speccify::Functions::build_matcher(name, args) do |given, matcher, args| given.send(($1 + "?").to_sym) end else raise NoMethodError.new(name.to_s) end end |