Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

OperatorMatcher uses wrong namespace #879

Closed
JakubRacek opened this Issue · 3 comments

2 participants

@JakubRacek

Hi, I am unable to run rspec command as it fails on an OperatorMatcher

OperatorMatcher used in https://github.com/rspec/rspec-rails/blob/master/lib/rspec/rails/matchers/relation_match_array.rb
should use BuiltIn namespace as defined in https://github.com/rspec/rspec-expectations/blob/master/lib/rspec/matchers/built_in.rb

@myronmarston

Yeah, I just merged that in rspec-expectations about an hour ago and we haven't gotten around to updating rspec-rails yet. Want to take a stab at a PR? (Otherwise one of us will).

Here's a work around you can use locally in the meantime if you're using rspec HEAD on a project and are blocked by this:

require 'rspec/matchers'

module RSpec
  module Matchers
    OperatorMatchers = BuiltIn::OperatorMatchers
  end
end
@JakubRacek

Ah, I have just made a pull request that adds the BuildIn namespace into the relation_match_array.rb.
I was not sure if you're working on it right now as I seen the commit you mentioned.

Shall I close the pull request?

@myronmarston

Shall I close the pull request?

Why would you close it? No, I'm not working on it. We're glad to merge user contributions. We'll merge that when it's green.

@JonRowe JonRowe closed this in b0167a7
@pcasaretto pcasaretto referenced this issue from a commit in ResultadosDigitais/rspec-rails
@JakubRacek JakubRacek OperatorMatcher should use BuiltIn namespace, fixes #879 e4cd216
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.