class Object
Public Instance Methods
match_type(object, type) { || ... }
click to toggle source
# File lib/rspec-rayo/matchers.rb, line 3 def match_type(object, type) unless object.is_a?(type) @error = "expected reason to be #{type}, got #{object}" raise RSpec::Expectations::ExpectationNotMetError end yield if block_given? object unless @error end