-
-
Notifications
You must be signed in to change notification settings - Fork 502
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cucumber v4 incompatibility #825
Comments
We're running into this problem as well when using use_scenario_name: true. Seems quite similar to (the ancient) #288. |
It seems the ability to obtain the feature name in before and after hooks has been removed in Cucumber v4. An issue has been raised in cucumber/cucumber-ruby#1432 to discuss the problem. |
Monkey-patch work-around while the issue is being discussed.
|
If anyone else is still dealing with this, this is what we're using now after a recent Cucumber/Gherkin change broke the above fix: module Cucumber
module RunningTestCase
class TestCase
def feature
::Gherkin::Parser.new.parse(File.read(location.file)).feature
end
end
end
end |
Do you "need" the feature name, or would just the location / something else wholly unique be good enough? |
It seems like using the |
Also ran into this issue and ended up using master. As this is already fixed in master by #845 I'll wait for the next release. The monkeypatch also works if you can't use vcr's master branch. |
Thanks for the notes, 6.1.0 contains the fix. Closing! |
There seems to be an incompatibility with the
VCR.cucumber_tags
functionality and the newly released Cucumber version 4.See the following backtrace detailing the error I am experiencing.
https://github.com/vcr/vcr/blob/v6.0.0/lib/vcr/test_frameworks/cucumber.rb#L51
VCR 6.0.0
Ruby 2.6.6
Gem 3.1.4
Rails 5.2.4.3
Cucumber 4.0.1
The text was updated successfully, but these errors were encountered: