Sha256: 77430ea81c5bc780e6a509f0159d2347372c9d7c1b4dce9ee72f09bffc04887a
Contents?: true
Size: 1.02 KB
Versions: 19
Compression:
Stored size: 1.02 KB
Contents
require 'spec/matchers/have' module Spec #:nodoc: module Matchers #:nodoc: class Have #:nodoc: def failure_message_for_should_with_errors_on_extensions return "expected #{relativities[@relativity]}#{@expected} errors on :#{@args[0]}, got #{@actual}" if @collection_name == :errors_on return "expected #{relativities[@relativity]}#{@expected} error on :#{@args[0]}, got #{@actual}" if @collection_name == :error_on return failure_message_for_should_without_errors_on_extensions end alias_method_chain :failure_message_for_should, :errors_on_extensions def description_with_errors_on_extensions return "have #{relativities[@relativity]}#{@expected} errors on :#{@args[0]}" if @collection_name == :errors_on return "have #{relativities[@relativity]}#{@expected} error on :#{@args[0]}" if @collection_name == :error_on return description_without_errors_on_extensions end alias_method_chain :description, :errors_on_extensions end end end
Version data entries
19 entries across 19 versions & 6 rubygems