Skip to content

Commit

Permalink
Merge pull request #801 from cucumber/fake-cucumber-handle-statuses
Browse files Browse the repository at this point in the history
Generate more realistic TestResult data in fake-cucumber
  • Loading branch information
aslakhellesoy authored Nov 27, 2019
2 parents 469bc6e + 068c21f commit a5a7b24
Show file tree
Hide file tree
Showing 17 changed files with 624 additions and 408 deletions.
Binary file modified cucumber-react/javascript/testdata/all.bin
Binary file not shown.
328 changes: 164 additions & 164 deletions cucumber-react/javascript/testdata/all.json

Large diffs are not rendered by default.

32 changes: 16 additions & 16 deletions cucumber-react/javascript/testdata/escaped_pipes.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
{"source":{"uri":"testdata/escaped_pipes.feature","data":"Feature: Escaped pipes\n The \\-character will be considered as an escape in table cell\n iff it is followed by a |-character, a \\-character or an n.\n\n Scenario: They are the future\n Given they have arrived\n | æ | o |\n | a | ø |\n Given they have arrived\n | \\\\\\n | \\o\\no\\ |\n | \\\\\\|a\\\\\\\\n | ø\\\\\\\\\\|\n","media":{"encoding":"UTF8","contentType":"text/x.cucumber.gherkin+plain"}}}
{"gherkinDocument":{"uri":"testdata/escaped_pipes.feature","feature":{"location":{"line":1,"column":1},"language":"en","keyword":"Feature","name":"Escaped pipes","description":" The \\-character will be considered as an escape in table cell\n iff it is followed by a |-character, a \\-character or an n.","children":[{"scenario":{"location":{"line":5,"column":3},"keyword":"Scenario","name":"They are the future","steps":[{"location":{"line":6,"column":5},"keyword":"Given ","text":"they have arrived","dataTable":{"location":{"line":7,"column":7},"rows":[{"location":{"line":7,"column":7},"cells":[{"location":{"line":7,"column":9},"value":"æ"},{"location":{"line":7,"column":13},"value":"o"}],"id":"74979a57-164a-4188-ac5d-975b533dac6a"},{"location":{"line":8,"column":7},"cells":[{"location":{"line":8,"column":9},"value":"a"},{"location":{"line":8,"column":13},"value":"ø"}],"id":"97213d69-0684-48c7-b5bc-26eb70b95d5f"}]},"id":"d5e6d893-cf39-45f7-bb60-a6d2f88e3779"},{"location":{"line":9,"column":5},"keyword":"Given ","text":"they have arrived","dataTable":{"location":{"line":10,"column":7},"rows":[{"location":{"line":10,"column":7},"cells":[{"location":{"line":10,"column":9},"value":"|æ\\n"},{"location":{"line":10,"column":22},"value":"\\o\no\\"}],"id":"7c5b25b8-8be4-4021-af7f-29441f511fbd"},{"location":{"line":11,"column":7},"cells":[{"location":{"line":11,"column":9},"value":"\\|a\\\\n"},{"location":{"line":11,"column":22},"value":"ø\\\nø\\"}],"id":"324aef51-5718-4194-a425-85df15e31ce1"}]},"id":"1543c8a7-2991-427d-a472-90a93777449b"}],"id":"6c18536e-9278-4e6e-83a7-cfc02a97215a"}}]}}}
{"pickle":{"id":"a74f9f83-0799-41d4-9300-20f30b0c55d0","uri":"testdata/escaped_pipes.feature","name":"They are the future","language":"en","steps":[{"text":"they have arrived","argument":{"dataTable":{"rows":[{"cells":[{"value":"æ"},{"value":"o"}]},{"cells":[{"value":"a"},{"value":"ø"}]}]}},"id":"3ec967aa-e056-44c1-959c-844b6168eb97","sourceIds":["d5e6d893-cf39-45f7-bb60-a6d2f88e3779"]},{"text":"they have arrived","argument":{"dataTable":{"rows":[{"cells":[{"value":"\\n"},{"value":"\\o\no\\"}]},{"cells":[{"value":"\\|a\\\\n"},{"value":"ø\\\nø\\"}]}]}},"id":"1444e4d5-2fd4-4077-952a-2818833a2579","sourceIds":["1543c8a7-2991-427d-a472-90a93777449b"]}],"sourceIds":["6c18536e-9278-4e6e-83a7-cfc02a97215a"]}}
{"stepDefinitionConfig":{"id":"4c074fa6-9870-4d6a-8dbb-99bc3f6ec078","pattern":{"source":"a passed {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"0076651e-adeb-41de-8483-ae2aee5d2574","pattern":{"source":"a passed step .*","type":"REGULAR_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"be987eef-a41a-4ecd-8c4e-3cd11a88b9f8","pattern":{"source":"I have {int} cukes/cucumbers in my {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"43afad0b-d47f-4c38-83e9-618bab9b798b","pattern":{"source":"a failed {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"4515aa6e-fd2e-43b1-90ec-069024770885","pattern":{"source":"a failed step .*","type":"REGULAR_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"26ad6026-08f5-42ff-9b6c-a8e75f8bf241","pattern":{"source":"a pending {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"5ef05bb0-e257-40da-96a9-860f54cf97af","pattern":{"source":"an ambiguou(s) {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"0fbf9222-c39b-42ed-b7a3-76eee647a06a","pattern":{"source":"an (a)mbiguous {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"testCase":{"id":"482d9158-3cd3-4eac-9612-7e034d03693e","pickleId":"a74f9f83-0799-41d4-9300-20f30b0c55d0","testSteps":[{"id":"8599a3c7-113a-4d3f-9db1-7f1a9bb85a15","pickleStepId":"3ec967aa-e056-44c1-959c-844b6168eb97"},{"id":"8891d1e4-05e2-4498-8de6-7946f7db3460","pickleStepId":"1444e4d5-2fd4-4077-952a-2818833a2579"}]}}
{"testCaseStarted":{"attempt":0,"testCaseId":"482d9158-3cd3-4eac-9612-7e034d03693e","id":"f44c5b42-76e7-4bf7-96f1-04e90ca7509b"}}
{"testStepStarted":{"testStepId":"8599a3c7-113a-4d3f-9db1-7f1a9bb85a15","testCaseStartedId":"f44c5b42-76e7-4bf7-96f1-04e90ca7509b"}}
{"testStepFinished":{"testResult":{"status":"UNDEFINED","duration":{"seconds":123,"nanos":456}},"testStepId":"8599a3c7-113a-4d3f-9db1-7f1a9bb85a15","testCaseStartedId":"f44c5b42-76e7-4bf7-96f1-04e90ca7509b"}}
{"testStepFinished":{"testResult":{"status":"SKIPPED","duration":{"seconds":123,"nanos":456}},"testStepId":"8891d1e4-05e2-4498-8de6-7946f7db3460","testCaseStartedId":"f44c5b42-76e7-4bf7-96f1-04e90ca7509b"}}
{"testCaseFinished":{"testResult":{"status":"UNDEFINED","duration":{"seconds":987654,"nanos":321}},"testCaseStartedId":"f44c5b42-76e7-4bf7-96f1-04e90ca7509b"}}
{"gherkinDocument":{"uri":"testdata/escaped_pipes.feature","feature":{"location":{"line":1,"column":1},"language":"en","keyword":"Feature","name":"Escaped pipes","description":" The \\-character will be considered as an escape in table cell\n iff it is followed by a |-character, a \\-character or an n.","children":[{"scenario":{"location":{"line":5,"column":3},"keyword":"Scenario","name":"They are the future","steps":[{"location":{"line":6,"column":5},"keyword":"Given ","text":"they have arrived","dataTable":{"location":{"line":7,"column":7},"rows":[{"location":{"line":7,"column":7},"cells":[{"location":{"line":7,"column":9},"value":"æ"},{"location":{"line":7,"column":13},"value":"o"}],"id":"2803ad06-712d-47cc-866e-cc9fcd2fbaf2"},{"location":{"line":8,"column":7},"cells":[{"location":{"line":8,"column":9},"value":"a"},{"location":{"line":8,"column":13},"value":"ø"}],"id":"a644b00c-2500-480c-b3f6-a30f95526539"}]},"id":"25ce3a54-3aa6-415e-a08b-e02aaa07c912"},{"location":{"line":9,"column":5},"keyword":"Given ","text":"they have arrived","dataTable":{"location":{"line":10,"column":7},"rows":[{"location":{"line":10,"column":7},"cells":[{"location":{"line":10,"column":9},"value":"|æ\\n"},{"location":{"line":10,"column":22},"value":"\\o\no\\"}],"id":"0291aacf-34f2-4c52-8a8d-9c424a838755"},{"location":{"line":11,"column":7},"cells":[{"location":{"line":11,"column":9},"value":"\\|a\\\\n"},{"location":{"line":11,"column":22},"value":"ø\\\nø\\"}],"id":"81de16bc-ccc1-4fbc-b3ff-5a5316c09353"}]},"id":"81147dfd-c3c8-4d98-8bea-a61949356670"}],"id":"08e921f0-7db7-44b9-b523-e8f3db7d6158"}}]}}}
{"pickle":{"id":"521ce854-d870-4673-b7a5-9a931cd54761","uri":"testdata/escaped_pipes.feature","name":"They are the future","language":"en","steps":[{"text":"they have arrived","argument":{"dataTable":{"rows":[{"cells":[{"value":"æ"},{"value":"o"}]},{"cells":[{"value":"a"},{"value":"ø"}]}]}},"id":"23dd506a-2c49-4a19-a2f9-28e93fe29524","sourceIds":["25ce3a54-3aa6-415e-a08b-e02aaa07c912"]},{"text":"they have arrived","argument":{"dataTable":{"rows":[{"cells":[{"value":"\\n"},{"value":"\\o\no\\"}]},{"cells":[{"value":"\\|a\\\\n"},{"value":"ø\\\nø\\"}]}]}},"id":"7710d585-3388-47c8-8f5a-a6c638b8dff3","sourceIds":["81147dfd-c3c8-4d98-8bea-a61949356670"]}],"sourceIds":["08e921f0-7db7-44b9-b523-e8f3db7d6158"]}}
{"stepDefinitionConfig":{"id":"87410bd7-ca11-4063-9ccb-c7613a500919","pattern":{"source":"a passed {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"7d384c3e-0097-444e-8b44-53759b967683","pattern":{"source":"a passed step .*","type":"REGULAR_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"07c1bd4d-3ff1-4c7e-8adb-76de364a8385","pattern":{"source":"I have {int} cukes/cucumbers in my {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"7030b8dd-5d11-4409-9749-09ad486cc556","pattern":{"source":"a failed {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"1c9cb3b1-fa17-4539-a6d2-4ba152fdbefc","pattern":{"source":"a failed step .*","type":"REGULAR_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"bbf566cb-2970-43be-8a59-6fe7ae28f5a6","pattern":{"source":"a pending {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"0d3fec9f-27e7-46e1-bf80-8e4b70ae953f","pattern":{"source":"an ambiguou(s) {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"stepDefinitionConfig":{"id":"c0225b95-edc4-4e25-a483-840147580c8f","pattern":{"source":"an (a)mbiguous {word}","type":"CUCUMBER_EXPRESSION"},"location":{"uri":"some/javascript/file.js","location":{"line":10,"column":3}}}}
{"testCase":{"id":"7b80c494-f356-45ab-bdd6-c71133b79182","pickleId":"521ce854-d870-4673-b7a5-9a931cd54761","testSteps":[{"id":"6794a786-aa61-4cd9-a260-87f5c09a9eb4","pickleStepId":"23dd506a-2c49-4a19-a2f9-28e93fe29524"},{"id":"1bcb205e-05a6-42e6-8d85-bd50d6eb258e","pickleStepId":"7710d585-3388-47c8-8f5a-a6c638b8dff3"}]}}
{"testCaseStarted":{"attempt":0,"testCaseId":"7b80c494-f356-45ab-bdd6-c71133b79182","id":"aedcf3dd-0037-48b3-a5fb-de4e41832a91"}}
{"testStepStarted":{"testStepId":"6794a786-aa61-4cd9-a260-87f5c09a9eb4","testCaseStartedId":"aedcf3dd-0037-48b3-a5fb-de4e41832a91"}}
{"testStepFinished":{"testResult":{"status":"UNDEFINED","duration":{"seconds":0,"nanos":0}},"testStepId":"6794a786-aa61-4cd9-a260-87f5c09a9eb4","testCaseStartedId":"aedcf3dd-0037-48b3-a5fb-de4e41832a91"}}
{"testStepFinished":{"testResult":{"status":"SKIPPED","duration":{"seconds":0,"nanos":0}},"testStepId":"1bcb205e-05a6-42e6-8d85-bd50d6eb258e","testCaseStartedId":"aedcf3dd-0037-48b3-a5fb-de4e41832a91"}}
{"testCaseFinished":{"testResult":{"status":"UNDEFINED","duration":{"seconds":0,"nanos":1150636.002421379}},"testCaseStartedId":"aedcf3dd-0037-48b3-a5fb-de4e41832a91"}}
Loading

0 comments on commit a5a7b24

Please sign in to comment.