Skip to content

Commit

Permalink
Merge pull request #757 from 10xtechie/The-10-minute-tutorial-does-no…
Browse files Browse the repository at this point in the history
…t-work-as-expected-#737

The 10 minute tutorial does not work as expected #737
  • Loading branch information
aurelien-reeves authored Jun 13, 2022
2 parents d454f7a + 432df51 commit ca3f12c
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 28 deletions.
55 changes: 28 additions & 27 deletions content/docs/guides/10-minute-tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -487,14 +487,8 @@ You should see something like the following:
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running hellocucumber.RunCucumberTest
No features found at [classpath:hellocucumber]

0 Scenarios
0 Steps
0m0.004s

Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.541 sec
Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

Results :

Expand Down Expand Up @@ -615,36 +609,43 @@ steps. It's also suggesting some snippets of code that we can use to
T E S T S
-------------------------------------------------------
Running hellocucumber.RunCucumberTest
Feature: Is it Friday yet?
Everybody wants to know when it's Friday

Scenario: Sunday isn't Friday # hellocucumber/is_it_friday_yet.feature:4
Given today is Sunday # null
When I ask whether it's Friday yet # null
Then I should be told "Nope" # null
Undefined scenarios:
hellocucumber/is_it_friday_yet.feature:4 # Sunday isn't Friday

1 Scenarios (1 undefined)
3 Steps (3 undefined)
0m0.040s


You can implement missing steps with the snippets below:
Scenario: Sunday isn't Friday # hellocucumber/is_it_friday_yet.feature:4
Given today is Sunday
When I ask whether it's Friday yet
Then I should be told "Nope"
┌───────────────────────────────────────────────────────────────────────────────────┐
│ Share your Cucumber Report with your team at https://reports.cucumber.io │
│ Activate publishing with one of the following: │
│ │
│ src/test/resources/cucumber.properties: cucumber.publish.enabled=true │
│ src/test/resources/junit-platform.properties: cucumber.publish.enabled=true │
│ Environment variable: CUCUMBER_PUBLISH_ENABLED=true │
│ JUnit: @CucumberOptions(publish = true) │
│ │
│ More information at https://cucumber.io/docs/cucumber/environment-variables/ │
│ │
│ Disable this message with one of the following: │
│ │
│ src/test/resources/cucumber.properties: cucumber.publish.quiet=true │
│ src/test/resources/junit-platform.properties: cucumber.publish.quiet=true │
└───────────────────────────────────────────────────────────────────────────────────┘
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.15 s <<< FAILURE! - in hellocucumber.RunCucumberTest
[ERROR] Is it Friday yet?.Sunday isn't Friday Time elapsed: 0.062 s <<< ERROR!
io.cucumber.junit.platform.engine.UndefinedStepException:
The step 'today is Sunday' and 2 other step(s) are undefined.
You can implement these steps using the snippet(s) below:
@Given("today is Sunday")
public void today_is_Sunday() {
public void today_is_sunday() {
// Write code here that turns the phrase above into concrete actions
throw new io.cucumber.java.PendingException();
}

@When("I ask whether it's Friday yet")
public void i_ask_whether_it_s_Friday_yet() {
public void i_ask_whether_it_s_friday_yet() {
// Write code here that turns the phrase above into concrete actions
throw new io.cucumber.java.PendingException();
}

@Then("I should be told {string}")
public void i_should_be_told(String string) {
// Write code here that turns the phrase above into concrete actions
Expand Down
2 changes: 1 addition & 1 deletion data/versions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ cucumberjs: "7.3.1"
cucumberruby: "7.1.0"
rspec: "3.10.0"
testng: "7.4.0"
junit: "4.13.2"
junit: "5.8.1"

0 comments on commit ca3f12c

Please sign in to comment.