inluxc / playwright-xray

XRAY reporter for Playwright
MIT License
25 stars 10 forks source link

Store PlayRight XRay Results #76

Open sn-sstone opened 2 weeks ago

sn-sstone commented 2 weeks ago

Is your feature request related to a problem? Please describe. It would be nice to be able to store the results of the XRAY Reporter somewhere, either in a file or env variable.

What is "Results": Things like what is provided at the end of the test run, such as.

😀 Successfully sending test results to Jira

⏺  Browsers:          Setup, Webkit
⏺  Test plan:         SNP-3674
⏺  Test Duration:     3h 32m 
⏺  Tests ran:         113 (including reruns)
⏺  Tests passed:      0
⏺  Tests failed:      113
⏺  Flaky tests:       0
⏺  Skipped tests:     0

-------------------------------------

⏺  Test execution SNP-4579 has been created
👇 Check out the test result
🔗 https://ABC.atlassian.net/browse/SNP-4579

It would need to be formatted in a way that individual data points ca be pragmatically fetched.

Describe the solution you'd like This way we can use this data to provide additional details to other reporters like https://github.com/ryanrosello-og/playwright-slack-report#readme. For example it would be nice to have a Slack message posted in a channel that says something like "Test Run Completed with 113 Failed 0 Passed. Check out the test results at 🔗 https://ABC.atlassian.net/browse/SNP-4579"

Describe alternatives you've considered None, as I do not think there is a way to get the data from this report console logs.

Additional context None.

Niklas-Back commented 2 weeks ago

Perhapps in a json file? E.g. runresult.json? { "browsers": "Setup, Webkit", "testPlan": "SNP-3674", "testDuration": "3h 32m", "testsRan": "113 (including reruns)", "testsPassed": "0", "testsFailed": "113", "flakyTests": "0", "skippedTests": "0" }

Or in CTRF? https://medium.com/@ma11hewthomas/its-finally-here-a-json-test-results-data-format-f485b77bbdbc

sn-sstone commented 1 week ago

yea I think a json file would be perfect.

Niklas-Back commented 1 week ago

A will add it in the next release