Undefined step definitions in IntelliJ

后端 未结 9 2446
予麋鹿
予麋鹿 2021-02-18 23:25

I\'m trying to follow this article to match Cucumber specs with step definitions in IntelliJ.

When I press Alt+Enter, I see Inspection \'Undefined Step\' options

相关标签:
9条回答
  • 2021-02-18 23:40

    I found that even with the Cucumber for Java plugin installed it was still generating only one step. I eventually uninstalled the Cucumber for Java plugin and reinstalled it and all step definitions were generated.

    0 讨论(0)
  • 2021-02-18 23:42

    Turns out I had the Gherkin plugin but not the Cucumber for Java plugin.

    0 讨论(0)
  • 2021-02-18 23:52

    For me there was a collision between Sidesteps plugin and Cucumber plugin in Intellij and as a result *.feature file extension was taken over by the Sidesteps plugin and was expecting Sidesteps step definitions ignoring Cucumber step definitions. No clue what Sidesteps actually is. So went to IntelliJ settings and reassigned the *.feature extension to Cucumber Scenario type and then everything worked fine and Cucumber steps are recognized by Intellij now.

    0 讨论(0)
提交回复
热议问题