Skip to content

Commit

Permalink
Update testcases
Browse files Browse the repository at this point in the history
  • Loading branch information
mpkorstanje committed Aug 27, 2024
1 parent 4ff7adb commit 982abb4
Show file tree
Hide file tree
Showing 17 changed files with 140 additions and 148 deletions.
193 changes: 90 additions & 103 deletions testdata/attachments.feature.ndjson

Large diffs are not rendered by default.

27 changes: 16 additions & 11 deletions testdata/attachments.feature.xml
Original file line number Diff line number Diff line change
@@ -1,53 +1,58 @@
<?xml version="1.0" encoding="UTF-8"?>
<testsuite name="Cucumber" time="0.061" tests="10" skipped="0" failures="0" errors="0">
<testcase classname="Attachments" name="Strings can be attached with a media type" time="0.005">
<testsuite name="Cucumber" time="0.045" tests="11" skipped="0" failures="0" errors="0">
<testcase classname="Attachments" name="Strings can be attached with a media type" time="0.003">
<system-out><![CDATA[
When the string "hello" is attached as "application/octet-stream"...........passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Log text" time="0.005">
<testcase classname="Attachments" name="Log text" time="0.003">
<system-out><![CDATA[
When the string "hello" is logged...........................................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Log ANSI coloured text" time="0.005">
<testcase classname="Attachments" name="Log ANSI coloured text" time="0.003">
<system-out><![CDATA[
When text with ANSI escapes is logged.......................................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Log JSON" time="0.005">
<testcase classname="Attachments" name="Log JSON" time="0.003">
<system-out><![CDATA[
When the following string is attached as "application/json":................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Byte arrays are base64-encoded regardless of media type" time="0.005">
<testcase classname="Attachments" name="Byte arrays are base64-encoded regardless of media type" time="0.003">
<system-out><![CDATA[
When an array with 10 bytes is attached as "text/plain".....................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Attaching JPEG images" time="0.005">
<testcase classname="Attachments" name="Attaching JPEG images" time="0.003">
<system-out><![CDATA[
When a JPEG image is attached...............................................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Attaching PNG images" time="0.005">
<testcase classname="Attachments" name="Attaching PNG images" time="0.003">
<system-out><![CDATA[
When a PNG image is attached................................................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Attaching images in an examples table - #1.1" time="0.005">
<testcase classname="Attachments" name="Attaching images in an examples table - #1.1" time="0.003">
<system-out><![CDATA[
When a JPEG image is attached...............................................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Attaching images in an examples table - #1.2" time="0.005">
<testcase classname="Attachments" name="Attaching images in an examples table - #1.2" time="0.003">
<system-out><![CDATA[
When a PNG image is attached................................................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Attaching PDFs with a different filename" time="0.005">
<testcase classname="Attachments" name="Attaching PDFs with a different filename" time="0.003">
<system-out><![CDATA[
When a PDF document is attached and renamed.................................passed
]]></system-out>
</testcase>
<testcase classname="Attachments" name="Attaching URIs" time="0.003">
<system-out><![CDATA[
When a link to "https://cucumber.io" is attached............................passed
]]></system-out>
</testcase>
</testsuite>
2 changes: 1 addition & 1 deletion testdata/cdata.feature.ndjson
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{"meta":{"ci":{"buildNumber":"154666429","git":{"remote":"https://github.com/cucumber-ltd/shouty.rb.git","revision":"99684bcacf01d95875834d87903dcb072306c9ad"},"name":"GitHub Actions","url":"https://github.com/cucumber-ltd/shouty.rb/actions/runs/154666429"},"cpu":{"name":"x64"},"implementation":{"name":"fake-cucumber","version":"16.4.0"},"os":{"name":"darwin","version":"23.0.0"},"protocolVersion":"22.0.0","runtime":{"name":"node.js","version":"20.8.0"}}}
{"meta":{"ci":{"buildNumber":"154666429","git":{"remote":"https://github.com/cucumber-ltd/shouty.rb.git","revision":"99684bcacf01d95875834d87903dcb072306c9ad"},"name":"GitHub Actions","url":"https://github.com/cucumber-ltd/shouty.rb/actions/runs/154666429"},"cpu":{"name":"x64"},"implementation":{"name":"fake-cucumber","version":"16.5.0"},"os":{"name":"darwin","version":"23.5.0"},"protocolVersion":"25.0.1","runtime":{"name":"node.js","version":"21.7.1"}}}
{"source":{"data":"Feature: cdata\n Cucumber xml formatters should be able to handle xml cdata elements\n\n Scenario: cdata\n Given I have 42 <![CDATA[cukes]]> in my belly\n","mediaType":"text/x.cucumber.gherkin+plain","uri":"samples/cdata/cdata.feature"}}
{"gherkinDocument":{"comments":[],"feature":{"children":[{"scenario":{"description":"","examples":[],"id":"2","keyword":"Scenario","location":{"column":3,"line":4},"name":"cdata","steps":[{"id":"1","keyword":"Given ","keywordType":"Context","location":{"column":5,"line":5},"text":"I have 42 <![CDATA[cukes]]> in my belly"}],"tags":[]}}],"description":" Cucumber xml formatters should be able to handle xml cdata elements","keyword":"Feature","language":"en","location":{"column":1,"line":1},"name":"cdata","tags":[]},"uri":"samples/cdata/cdata.feature"}}
{"pickle":{"astNodeIds":["2"],"id":"4","language":"en","name":"cdata","steps":[{"astNodeIds":["1"],"id":"3","text":"I have 42 <![CDATA[cukes]]> in my belly","type":"Context"}],"tags":[],"uri":"samples/cdata/cdata.feature"}}
Expand Down
2 changes: 1 addition & 1 deletion testdata/data-tables.feature.ndjson
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{"meta":{"ci":{"buildNumber":"154666429","git":{"remote":"https://github.com/cucumber-ltd/shouty.rb.git","revision":"99684bcacf01d95875834d87903dcb072306c9ad"},"name":"GitHub Actions","url":"https://github.com/cucumber-ltd/shouty.rb/actions/runs/154666429"},"cpu":{"name":"x64"},"implementation":{"name":"fake-cucumber","version":"16.4.0"},"os":{"name":"darwin","version":"23.0.0"},"protocolVersion":"22.0.0","runtime":{"name":"node.js","version":"20.8.0"}}}
{"meta":{"ci":{"buildNumber":"154666429","git":{"remote":"https://github.com/cucumber-ltd/shouty.rb.git","revision":"99684bcacf01d95875834d87903dcb072306c9ad"},"name":"GitHub Actions","url":"https://github.com/cucumber-ltd/shouty.rb/actions/runs/154666429"},"cpu":{"name":"x64"},"implementation":{"name":"fake-cucumber","version":"16.5.0"},"os":{"name":"darwin","version":"23.5.0"},"protocolVersion":"25.0.1","runtime":{"name":"node.js","version":"21.7.1"}}}
{"source":{"data":"Feature: Data Tables\n Data Tables can be placed underneath a step and will be passed as the last\n argument to the step definition.\n\n They can be used to represent richer data structures, and can be transformed to other data-types.\n\n Scenario: transposed table\n When the following table is transposed:\n | a | b |\n | 1 | 2 |\n Then it should be:\n | a | 1 |\n | b | 2 |\n","mediaType":"text/x.cucumber.gherkin+plain","uri":"samples/data-tables/data-tables.feature"}}
{"gherkinDocument":{"comments":[],"feature":{"children":[{"scenario":{"description":"","examples":[],"id":"8","keyword":"Scenario","location":{"column":3,"line":7},"name":"transposed table","steps":[{"dataTable":{"location":{"column":7,"line":9},"rows":[{"cells":[{"location":{"column":9,"line":9},"value":"a"},{"location":{"column":13,"line":9},"value":"b"}],"id":"2","location":{"column":7,"line":9}},{"cells":[{"location":{"column":9,"line":10},"value":"1"},{"location":{"column":13,"line":10},"value":"2"}],"id":"3","location":{"column":7,"line":10}}]},"id":"4","keyword":"When ","keywordType":"Action","location":{"column":5,"line":8},"text":"the following table is transposed:"},{"dataTable":{"location":{"column":7,"line":12},"rows":[{"cells":[{"location":{"column":9,"line":12},"value":"a"},{"location":{"column":13,"line":12},"value":"1"}],"id":"5","location":{"column":7,"line":12}},{"cells":[{"location":{"column":9,"line":13},"value":"b"},{"location":{"column":13,"line":13},"value":"2"}],"id":"6","location":{"column":7,"line":13}}]},"id":"7","keyword":"Then ","keywordType":"Outcome","location":{"column":5,"line":11},"text":"it should be:"}],"tags":[]}}],"description":" Data Tables can be placed underneath a step and will be passed as the last\n argument to the step definition.\n\n They can be used to represent richer data structures, and can be transformed to other data-types.","keyword":"Feature","language":"en","location":{"column":1,"line":1},"name":"Data Tables","tags":[]},"uri":"samples/data-tables/data-tables.feature"}}
{"pickle":{"astNodeIds":["8"],"id":"11","language":"en","name":"transposed table","steps":[{"argument":{"dataTable":{"rows":[{"cells":[{"value":"a"},{"value":"b"}]},{"cells":[{"value":"1"},{"value":"2"}]}]}},"astNodeIds":["4"],"id":"9","text":"the following table is transposed:","type":"Action"},{"argument":{"dataTable":{"rows":[{"cells":[{"value":"a"},{"value":"1"}]},{"cells":[{"value":"b"},{"value":"2"}]}]}},"astNodeIds":["7"],"id":"10","text":"it should be:","type":"Outcome"}],"tags":[],"uri":"samples/data-tables/data-tables.feature"}}
Expand Down
Loading

0 comments on commit 982abb4

Please sign in to comment.