class Transpec::Syntax::RaiseError
Public Instance Methods
dynamic_analysis_target?()
click to toggle source
Calls superclass method
Transpec::Syntax#dynamic_analysis_target?
# File lib/transpec/syntax/raise_error.rb, line 12 def dynamic_analysis_target? super && receiver_node.nil? && method_name == :raise_error end
remove_error_specification_with_negative_expectation!()
click to toggle source
# File lib/transpec/syntax/raise_error.rb, line 16 def remove_error_specification_with_negative_expectation! return if expectation.positive? return unless specific_error? remove(parentheses_range) add_record(RecordBuilder.build(self)) end
specific_class?()
click to toggle source
# File lib/transpec/syntax/raise_error.rb, line 27 def specific_class? specific_error? && arg_nodes.first.const_type? end
specific_error?()
click to toggle source
# File lib/transpec/syntax/raise_error.rb, line 23 def specific_error? !arg_nodes.empty? end
specific_message?()
click to toggle source
# File lib/transpec/syntax/raise_error.rb, line 31 def specific_message? if specific_class? arg_nodes.count >= 2 else specific_error? end end