Skip to content

[Question]: Ctrl+Click goes to wrong step when two steps share a prefix #351

Description

@NikkTod

Question

Hey @vitalets hope you can help me with that issue below:

Problem summary

I have two steps where one is a prefix of the other:

And I click on "X"
And I click on "X" for table row with label "Y"

Step definitions (decorators):

@when('I click on {string}')

@when('I click on {string} for table row with label {string}')

Actual behavior

With default settings, Ctrl+Click on the long step in the .feature file jumps to the short step definition.

Expected behavior

Ctrl+Click on I click on "{string}" for table row with label "{string}" should navigate to its own definition, not the shorter one.


"cucumberautocomplete.syncfeatures": "src/**/*.feature",
    "cucumberautocomplete.strictGherkinCompletion": false,
    "cucumberautocomplete.strictGherkinValidation": false,
    "cucumberautocomplete.smartSnippets": true,
    "cucumberautocomplete.onTypeFormat": true,
    "editor.quickSuggestions": {
        "comments": false,
        "strings": true,
        "other": true
    },

I also tried pureTextSteps = true, but it did not help

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions