Call fail instead of failure on visitor

This commit is contained in:
Michael Miller 2021-05-15 19:42:59 -06:00
parent 618e9e195a
commit d5c4d5e822
No known key found for this signature in database
GPG key ID: F9A0C5C65B162436

View file

@ -17,12 +17,12 @@ module Spectator
# Calls the `failure` method on *visitor*. # Calls the `failure` method on *visitor*.
def accept(visitor) def accept(visitor)
visitor.failure visitor.fail
end end
# Calls the `failure` method on *visitor*. # Calls the `failure` method on *visitor*.
def accept(visitor) def accept(visitor)
visitor.failure(yield self) visitor.fail(yield self)
end end
# Indicates whether the example passed. # Indicates whether the example passed.