-
-
Notifications
You must be signed in to change notification settings - Fork 50
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
Fix DataTable's Location to be aware of all of its lines #142
Fix DataTable's Location to be aware of all of its lines #142
Conversation
Hello @botandrose! It looks like the rest of the specs for location matching are here: https://github.com/cucumber/cucumber-ruby-core/blob/master/spec/cucumber/core/test/filters/locations_filter_spec.rb Maybe just add another example after this one? |
c01a0cd
to
09009a0
Compare
09009a0
to
eca5299
Compare
@mattwynne Thanks for the pointer! Indeed, that appears to be exactly the right place to add tests for this. I just rebased, squashed, and force-pushed. As an aside, I've only recently gotten the commit-bit. What's the etiquette for merging PRs? Can I merge my own PRs in clear-cut situations like this? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @botandrose - I've reviewed this and I approve! Nice fix, good tests and clean code!
Go ahead and merge. I'd like to review a few more pull requests before we offer you a seat by the core team if you don't mind. Then you'll be free to merge your own pull requests (reviews will be at your discretion).
Keep up the good work!
Roger that! Thanks for the review! |
Hi @botandrose, Thanks for your making your first contribution to Cucumber, and welcome to the Cucumber committers team! You can now push directly to this repo and all other repos under the cucumber organization! 🍾 In return for this generous offer we hope you will:
On behalf of the Cucumber core team, |
@botandrose - one more thing. Please update the changelog - you can do it on master. Add an entry to the top. Thanks |
Sorry for the delay... just got back into town from the eclipse 🌑! HISTORY.md is updated. |
## [3.0.0](cucumber/cucumber-ruby-core@v3.0.0.pre.2...v3.0.0) (2017-09-27) ### Changed * Step#name renamed to #text ([#137](cucumber/cucumber-ruby-core#137) [@olleolleolle](https://github.com/olleolleolle)) * Use past tense in event names (`xStarting` -> `xStarted`) (see [cucumber/cucumber-ruby#1166](cucumber/cucumber-ruby#1166) @brasmusson). ### Added * Do not create test cases for scenarios with no steps ([#144](cucumber/cucumber-ruby-core#144) @brasmusson) * Handle selective strict settings ([#143](cucumber/cucumber-ruby-core#143) @brasmusson) ### Fixed * Fix DataTable's Location to be aware of all of its lines ([#142](cucumber/cucumber-ruby-core#142) @botandrose) ### Improved * As per [#251](cucumber/common#251): renamed History.md to CHANGELOG.md, added contributing message at beginning, and misc formatting. ([#145](cucumber/cucumber-ruby-core#145) [jaysonesmith](https://github.com/jaysonesmith)) ## [3.0.0.pre.2](cucumber/cucumber-ruby-core@v2.0.0...3.0.0.pre.2) (2017-07-26) ### New Features * Add a flaky result type to be used for flaky scenarios ([#141](cucumber/cucumber-ruby-core#141), [cucumber/cucumber-ruby#1044](cucumber/cucumber-ruby#1044) @brasmusson) * Make the Summary report able to say if the total result is ok ([#140](cucumber/cucumber-ruby-core#140) @brasmusson) * Replay previous events to new subscribers ([#136](cucumber/cucumber-ruby-core#136) @mattwynne) * Ruby 2.4.0 compatibility ([#120](cucumber/cucumber-ruby-core#120) @junaruga) * Use tag expressions ([#116](cucumber/cucumber-ruby-core#116) @brasmusson) * Access example table row data by param name ([#118](cucumber/cucumber-ruby-core#118) @enkessler) ### Bugfixes N/A ### Removed Features N/A ### Refactoring * Travis: jruby-9.1.10.0 ([#130](cucumber/cucumber-ruby-core#130) @olleolleolle) * Travis: jruby-9.1.12.0 ([#133](cucumber/cucumber-ruby-core#132) @olleolleolle)
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Hi folks! I'm back with another DataTable-related bugfix. When being built, DataTables would build their
Ast::Location
with only the first line. In the following example feature, this led to commands likecucumber features/test.feature:5
working, butcucumber features/test.feature:6
not running any tests, because noTest::Case
reported containing that line.How Has This Been Tested?
I'm not quite sure how best to test this. My first inclination is to add a unit test, but there appear to be no unit tests in this project for
Cucumber::Core::Gherkin::AstBuilder
or any of its internals. The cucumber acceptance test above could be added to the parentcucumber/cucumber-ruby
project, but it seems a bit too edge-casey for a full acceptance test, IMO. Thoughts?Types of changes
Checklist: