Skip to content

Unable to add new steps, any idea why? - undefined steps whatever I try #3

Description

@mickael28

I've created a new feature under /test/resources and added a new step there,eg:

  • And I enter the wrong number
    

Then I've put the implementation:
`@Given("^I enter the wrong council tax number$")

public void i_enter_the_wrong_council_tax_number() throws Throwable {
// Write code here that turns the phrase above into concrete actions
throw new PendingException();
}`

Inside the test/java/info.seleniumcucumber.userStepDefintions/UserStepDefinitions file, and when I run the test I still get

`1 Scenarios (1 undefined)
3 Steps (1 undefined, 2 passed)
0m9.609s

You can implement missing steps with the snippets below:

@given("^I enter the wrong council tax number$")

public void i_enter_the_wrong_council_tax_number() throws Throwable {
// Write code here that turns the phrase above into concrete actions
throw new PendingException();
}
`

I've tried creating a new package and putting it there:

  • package stepsdefinitions;

And then expanding the RunCukeTest file with:
` glue = {"info.seleniumcucumber.stepsdefinitions", // predefined step definitions package

"info.seleniumcucumber.userStepDefintions", // user step definitions package (NOTE it will contain a lot of classes)

"stepsdefinitions"
}`

But I keep on getting that undefined error, any clue what the failure could be?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions