Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
fix(cucumber): a sequence of activities is correctly reported
affects: @serenity-js/core, @serenity-js-examples/cucumber
- Loading branch information
Showing
with
87 additions
and 30 deletions.
- +17 −0 examples/cucumber/features/reporting_results/narrative.txt
- +21 −0 examples/cucumber/features/reporting_results/reports_passing_scenarios.feature
- +0 −9 examples/cucumber/features/sample.feature
- +5 −5 examples/cucumber/features/step_definitions/sample.steps.ts
- +1 −1 examples/cucumber/features/support/configure_serenity.ts
- +5 −3 examples/cucumber/package.json
- +22 −0 packages/core/spec/stage/crew/serenity-bdd-reporter/SerenityBDDReporter/reporting_activities.spec.ts
- +16 −12 packages/core/src/stage/crew/serenity-bdd-reporter/ScenarioReport.ts
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1,17 @@ | ||
Reporting Results | ||
|
||
Narrative: | ||
In order to quickly learn how to use Serenity/JS with Cucumber | ||
As a busy developer | ||
I'd like to see examples demonstrating how Serenity/JS reports the result of executing Cucumber test scenarios. | ||
|
||
This note is called _"the narrative"_. It can be used to provide the context around the business capability of your | ||
product ("Reporting Results" in this case) and its features that help to enable this capability. | ||
|
||
**Please note:** While [Cucumber](https://github.com/cucumber/cucumber-js) allows you to capture a description | ||
of each feature in the `.feature` file, [Serenity/JS](https://serenityjs.org) allows us to group those `.feature` | ||
files in directories corresponding to "epics", "themes" or "business capabilities" of your system and provide | ||
each one of those with additional context using this `narrative.txt` file. | ||
|
||
**By the way:** Did you notice that you can use **[markdown syntax](https://www.markdownguide.org/)** to better express | ||
your thoughts? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1,21 @@ | ||
Feature: Reports passing scenarios | ||
|
||
In order to see how Serenity/JS reports a passing Cucumber scenario | ||
As a curious developer | ||
I'd like to see an example implementation | ||
|
||
Scenario: A passing scenario | ||
|
||
Here's an example of a passing scenario. | ||
The rule here is simple: | ||
- provided that all the steps pass | ||
- the scenario passes as well. | ||
|
||
Did you notice that we've used [markdown](https://www.markdownguide.org/) here again? | ||
|
||
This comes in handy when you want to link to external files such as architecture diagrams, wireframes or additional | ||
documentation. | ||
|
||
Given a step that passes | ||
When another step passes | ||
Then the third step passes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters