diff --git a/README.md b/README.md index 777d52f..f2f6846 100644 --- a/README.md +++ b/README.md @@ -78,7 +78,8 @@ Feature: Rules ``` Likewise for example tables, the rule (if any), scenario outline name, example -name, and number are included. +name, and number are included. Additionally, if the scenario outline name is +parameterized, the pickle name is included too. ```feature Feature: Examples Tables @@ -97,13 +98,27 @@ Feature: Examples Tables | start | eat | left | | 12 | 20 | 0 | | 0 | 1 | 0 | + + Scenario Outline: Eating cucumbers + Given I am transparent + When I eat cucumbers + Then I become + + Examples: + | color | + | red | + | green | + | blue | ``` ```xml - - - - + + + + + + + ``` ## Contributing diff --git a/java/src/main/java/io/cucumber/junitxmlformatter/MessagesToJunitXmlWriter.java b/java/src/main/java/io/cucumber/junitxmlformatter/MessagesToJunitXmlWriter.java index ffbed07..68df541 100644 --- a/java/src/main/java/io/cucumber/junitxmlformatter/MessagesToJunitXmlWriter.java +++ b/java/src/main/java/io/cucumber/junitxmlformatter/MessagesToJunitXmlWriter.java @@ -27,7 +27,7 @@ public class MessagesToJunitXmlWriter implements AutoCloseable { private boolean streamClosed = false; public MessagesToJunitXmlWriter(OutputStream out) { - this(NamingStrategy.ExampleName.NUMBER, out); + this(NamingStrategy.ExampleName.NUMBER_AND_PICKLE_IF_PARAMETERIZED, out); } public MessagesToJunitXmlWriter(NamingStrategy.ExampleName exampleNameStrategy, OutputStream out) { diff --git a/testdata/attachments.feature.xml b/testdata/attachments.feature.xml index 04abaac..6ffcef8 100644 --- a/testdata/attachments.feature.xml +++ b/testdata/attachments.feature.xml @@ -35,12 +35,12 @@ When a JPEG image is attached...............................................pass When a PNG image is attached................................................passed ]]> - + - + diff --git a/testdata/examples-tables.feature.xml b/testdata/examples-tables.feature.xml index 0e78e3c..18ac4fd 100644 --- a/testdata/examples-tables.feature.xml +++ b/testdata/examples-tables.feature.xml @@ -1,20 +1,20 @@ - + - + - + + + - + - + - +