Module: RSpec::Expectations::Syntax::ExpectExpressionGenerator Private
- Defined in:
- lib/rspec/expectations/syntax.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Generates expectation expressions for the expect
syntax.
Class Method Summary (collapse)
- + (Object) negative_expression(target_expression, matcher_expression) private
- + (Object) positive_expression(target_expression, matcher_expression) private
Class Method Details
+ (Object) negative_expression(target_expression, matcher_expression)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
158 159 160 |
# File 'lib/rspec/expectations/syntax.rb', line 158 def self.negative_expression(target_expression, matcher_expression) "expect(#{target_expression}).not_to #{matcher_expression}" end |
+ (Object) positive_expression(target_expression, matcher_expression)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
154 155 156 |
# File 'lib/rspec/expectations/syntax.rb', line 154 def self.positive_expression(target_expression, matcher_expression) "expect(#{target_expression}).to #{matcher_expression}" end |