Sha256: 15f512bad7f6cbf5ab1f13cf38c71272adde83319e3c71f3ea77cf90e4dd4301

Contents?: true

Size: 431 Bytes

Versions: 31

Compression:

Stored size: 431 Bytes

Contents

module RSpec
  module Core
    module Matchers
      def fail
        raise_error(::RSpec::Expectations::ExpectationNotMetError)
      end

      def fail_with(message)
        raise_error(::RSpec::Expectations::ExpectationNotMetError, message)
      end
    end
  end
end

RSpec::Matchers.define :be_one_of do |*list|
  match do |item|
    list.include? item or list.select { |i| i.is_a? Regexp }.any? { |r| item =~ r }
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
pacer-2.0.24-java spec/support/matchers.rb
pacer-2.0.22-java spec/support/matchers.rb
pacer-2.0.20-java spec/support/matchers.rb
pacer-2.0.19-java spec/support/matchers.rb
pacer-2.0.18-java spec/support/matchers.rb
pacer-2.0.17-java spec/support/matchers.rb
pacer-2.0.16-java spec/support/matchers.rb
pacer-2.0.15-java spec/support/matchers.rb
pacer-2.0.14-java spec/support/matchers.rb
pacer-2.0.13-java spec/support/matchers.rb
pacer-2.0.12-java spec/support/matchers.rb
pacer-2.0.10-java spec/support/matchers.rb
pacer-2.0.10.pre-java spec/support/matchers.rb
pacer-2.0.8-java spec/support/matchers.rb
pacer-2.0.6-java spec/support/matchers.rb
pacer-2.0.4.pre-java spec/support/matchers.rb
pacer-2.0.0.pre-java spec/support/matchers.rb
pacer-1.6.0-java spec/support/matchers.rb
pacer-1.5.4-java spec/support/matchers.rb
pacer-1.5.3-java spec/support/matchers.rb