-
Notifications
You must be signed in to change notification settings - Fork 11
Fix 95: Ambiguous step reported when definition matches via more than one tag #96
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
Conversation
…epDefinitions that have mutliple tags.
…ly take the first binding of those that match on multiple scopes but resolve to the same Implementation. Added a unit test and a Spec test.
|
Build failed one Spec about Completions that has nothing to do with this PR. I didn't change anything (at least I think not). |
|
I've restarted the build, maybe it's a flaky test |
Thanks. But that one failed too in the same place. It's a test related to editor completions. I'll look at it tomorrow. |
…tepdefinitions that have multiple scope tags without interfering with how it was being done for other tests.
Fixed the problem; it was my fault in how the test step definitions were getting defined. |
|
@clrudolphi I see that your test is working (and red when the code change isn't there) But I'm curious how it works, as So this is deduplicated by reference? Isn't that tricky? |
Yes, We have a few options:
-2 is probably OK but I'm not sure if we would inadvertently break something elsewhere that was depending upon reference equality. Do you see anything I may have overlooked? Any preferences? |
|
I prefer 3, so it won't break in the future:) |
…e semantics are clear when the ProjectBindingRegistry disambiguates possibly ambiguous step definitions that happen to have multiple matching Scopes.
Implemented ( number 3, the |
🤔 What's changed?
Modified the ProjectBindingRegistry to ignore duplicate matches when the Implementations were the same but differed only in the Scope of the match.
⚡️ What's your motivation?
Fixes #95
🏷️ What kind of change is this?
♻️ Anything particular you want feedback on?
📋 Checklist:
This text was originally taken from the template of the Cucumber project, then edited by hand. You can modify the template here.