Skip to content
This repository was archived by the owner on Nov 30, 2024. It is now read-only.
This repository was archived by the owner on Nov 30, 2024. It is now read-only.

Possible regression in pattern configuration for 2.14 #993

@iamvery

Description

@iamvery

I have managed to narrow an issue with turnip down to what may be a regression in RSpec 2.14.

It seems that specifying additional patterns to match files on does that load specs in those files under 2.14. This is how turnip managed to load .feature files for their gherkin features.

I dug into RSpec's source a bit and observed that files_to_run appears to get set earlier under 2.14 and is not updated when the pattern is changed. I'm not completely sure what that means and was not able to narrow down the change.


I did however come up with a simplified example and steps to reproduce:

bundle install # make sure 2.13 is installed
bundle exec rspec
  • Observe that two specs are run (the one in a_spec.rb and a_test.rb)
  • Check out commit tag using RSpec 2.14 bundle git checkout rspec-2.14
  • Run the specs under 2.14
bundle install # make sure 2.14 is installed
bundle exec rspec
  • Observe that only one spec is run (the one in a_spec.rb)

Hopefully these instructions are clear. I wasn't 💯 sure of the best way to ensure my example could be run with different versions of RSpec.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions