inluxc / playwright-xray

XRAY reporter for Playwright
MIT License
27 stars 11 forks source link

Adding functionality for Flaky and skip upload of evidence #58

Closed Niklas-Back closed 8 months ago

Niklas-Back commented 9 months ago

I have added these features but I would like to hear your thoughts before committing.

If playwright re-tries to run a test that failed it is considered flaky. In my implementation I search for testkeys that are both PASSED and FAILED. If two or more such testruns are encountered the passed testrun will be tagged according to a setting in playwright.config.ts e.g. markFlakyWith: "FLAKY" and all failed ones will be removed. E.g. if TES-49 fails twice and then passes on the third run then the two failed ones will be removed from the Xray import and the passed one will get the status defined in markFlakyWith. If markFlakyWith is absent the test will get status passed.

I also added settings to avoid upload evidence to Xray due to the 100MiByte limit of the Xray import with the boolean settings uploadScreenShot, uploadTrace and uploadVideo.

Extract from the readme:

image

inluxc commented 9 months ago

Hi there, thanks for the help, I bit loaded lately. It looks great, go for it, and go ahead and review the PR.

Niklas-Back commented 9 months ago

Thanks, I'll just let it run in our CI for a couple of days in order to iron out any bugs

HamzaMiz commented 9 months ago

@Niklas-Back great thoughts i hope it works waiting for the update