Closed mjnohai closed 4 years ago
removing the cuke_linter
gem, I was able to run the tests again.
Off hand, cuke_linter
does not appear to be the problem because it is not anywhere in that stack trace. That being said, I am curious what the difference is between the two different lockfiles generated by Bundler when you have CukeLinter listed as a dependency vs when you don't. My guess is that the inclusion of the cuke_linter
in your gemset causes Bundler to generate different transitive dependencies and it is in those transitive dependencies that the problem lies.
@mnohai-mdsol Which version of cuke_modeler
is Bundler pulling in as a dependency for cuke_linter
? Newer versions of CukeModeler use the cucumber-gherkin
gem, which does not work with earlier versions of the cucumber
gem (according to that stack trace, you are using 3.2) due to the transition from gherkin
to cucumber-gherkin
that Cucumber underwent recently. In other words, I think that you may be running into this.
Try either upgrading to Cucumber 4.x+ or limiting CukeModeler to < 3.x and see if that allows you to have CukeLinter in your bundle without encountering errors.
Given that the root cause of this issue in with another gem and a workaround exists, I'm going to close this issue.
I get the following error when running cucumber tests.
bundle exec cucumber features/imedidata/smoke_imedidata_nav.feature Knapsack time offset warning enabled! undefined method
keys' for #rubify_keys' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core/gherkin/ast_builder.rb:32:in
initialize' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core/gherkin/ast_builder.rb:125:ininitialize' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core/gherkin/ast_builder.rb:106:in
new' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core/gherkin/ast_builder.rb:106:infeature' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core/gherkin/ast_builder.rb:17:in
feature' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core/gherkin/parser.rb:32:indocument' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core.rb:30:in
block in parse' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core.rb:29:ineach' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core.rb:29:in
parse' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-core-3.2.1/lib/cucumber/core.rb:21:incompile' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-3.2.0/lib/cucumber/runtime.rb:75:in
run!' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-3.2.0/lib/cucumber/cli/main.rb:34:inexecute!' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/gems/cucumber-3.2.0/bin/cucumber:9:in
<top (required)>' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/bin/cucumber:23:inload' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/bin/cucumber:23:in
eval' /Users/mnohai/.rvm/gems/ruby-2.6.6@mist/bin/ruby_executable_hooks:24:in