Class: Transpec::Syntax::MethodStub::NoMessageAllowanceRecord
- Defined in:
- lib/transpec/syntax/method_stub.rb
Instance Method Summary collapse
- #converted_syntax ⇒ Object
-
#initialize(method_stub) ⇒ NoMessageAllowanceRecord
constructor
A new instance of NoMessageAllowanceRecord.
- #original_syntax ⇒ Object
Methods inherited from Record
Constructor Details
#initialize(method_stub) ⇒ NoMessageAllowanceRecord
Returns a new instance of NoMessageAllowanceRecord.
241 242 243 |
# File 'lib/transpec/syntax/method_stub.rb', line 241 def initialize(method_stub, *) @method_stub = method_stub end |
Instance Method Details
#converted_syntax ⇒ Object
252 253 254 |
# File 'lib/transpec/syntax/method_stub.rb', line 252 def converted_syntax base_syntax end |
#original_syntax ⇒ Object
245 246 247 248 249 250 |
# File 'lib/transpec/syntax/method_stub.rb', line 245 def original_syntax syntax = base_syntax syntax << '.any_number_of_times' if @method_stub.any_number_of_times? syntax << '.at_least(0)' if @method_stub.at_least_zero? syntax end |