Sha256: 0cda7b3082202b66a567468c705381a72d99bf879f6a77e553404c5a4da47e16
Contents?: true
Size: 558 Bytes
Versions: 37
Compression:
Stored size: 558 Bytes
Contents
class BeEqualTo def initialize(expectation) @expectation = expectation end def matches?(instance) @instance = instance return @instance == @expectation end def description "be equal to #{@expectation}" end def failure_message " expected to be equal to #{@expectation}, but was not, and had the following errors:\n #{@instance}" end def negative_failure_message " expected to not be valid, but was. (Are you missing a validation?)" end end def be_equal_to(expectation) BeEqualTo.new(expectation) end
Version data entries
37 entries across 37 versions & 2 rubygems