lib/micro/case/error.rb in u-case-3.0.0.rc3 vs lib/micro/case/error.rb in u-case-3.0.0.rc4
- old
+ new
@@ -2,12 +2,14 @@
module Micro
class Case
module Error
class UnexpectedResult < TypeError
- MESSAGE = '#call! must return an instance of Micro::Case::Result'.freeze
+ MESSAGE = 'must return an instance of Micro::Case::Result'.freeze
- def initialize(klass); super(klass.name + MESSAGE); end
+ def initialize(context)
+ super("#{context} #{MESSAGE}")
+ end
end
class ResultIsAlreadyDefined < ArgumentError
def initialize; super('result is already defined'.freeze); end
end