Open jreyes-fy opened 2 weeks ago
Looks like ansi codes are not properly filtered out from comment. Can you please send the report file after dry run (just run the test in question)
Hi Niklas, please find attached the file. I would really appreciate your help on this and other tickets I submitted. xray-payload.json
I will try to add an ansi filter
I have updated the ansi filtering, but the problem is that when I run it in our pipelines it strips away the ansi characters correctly (with the old and the new filter) so I wonder if I can send you a package to test before releasing?
Hi @Niklas-Back sure send me the package, I can test it
hey @Niklas-Back same result with 0.6.7 xray-payload.json
Ok, I think I have to get hold of a Mac so I can debug
or Linux, I am getting the same issue when running from GH Actions, running on ubuntu-latest, the comment looks the same in XRay.
Hi, do you have time for a debugging session? I didnt manage to reproduce it in Github Actions or on a Mac
Hi Niklas, sure, let me know when you are available and I can schedule a meeting in the coming days
Hi, Im based in Stockholm so Im at CET. Thursday or Friday. How can I contact you?
Added the reporter to config file to get results in Jira XRay test execution. The failed test is a text comparison.
The tests run in Github Actions, test execution is created in XRAy. However, the comment column contains the error message as follows:
[{"message":"Error: \u001b[2mexpect(\u001b[22m\u001b[31mreceived\u001b[39m\u001b[2m).\u001b[22mtoEqual\u001b[2m(\u001b[22m\u001b[32mexpected\u001b[39m\u001b[2m) // deep equality\u001b[22m\n\nExpected: \u001b[32m\"Test\"\u001b[39m\nReceived: \u001b[31m\"Incorrect username or password.\"\u001b[39m","stack":"Error: \u001b[2mexpect(\u001b[22m\u001b[31mreceived\u001b[39m\u001b[2m).\u001b[22mtoEqual\u001b[2m(\u001b[22m\u001b[32mexpected\u001b[39m\u001b[2m) // deep equality\u001b[22m\n\nExpected: \u001b[32m\"Test\"\u001b[39m\nReceived: \u001b[31m\"Incorrect username or password.\"\u001b[39m\n at /home/runner/work/qa-automation-ui/qa-automation-ui/fitConsole/tests/loginTest.spec.ts:23:26","location":{"file":"/home/runner/work/qa-automation-ui/qa-automation-ui/fitConsole/tests/loginTest.spec.ts","column":26,"line":23},"snippet":"\u001b[0m \u001b[90m 21 |\u001b[39m \u001b[36mawait\u001b[39m loginPage\u001b[33m.\u001b[39mlogin(username\u001b[33m,\u001b[39m \u001b[32m\"WrgPwd\"\u001b[39m)\u001b[33m;\u001b[39m\n \u001b[90m 22 |\u001b[39m \u001b[36mconst\u001b[39m errorMessage \u001b[33m=\u001b[39m \u001b[36mawait\u001b[39m loginPage\u001b[33m.\u001b[39mgetErrorMessage()\u001b[33m;\u001b[39m\n\u001b[31m\u001b[1m>\u001b[22m\u001b[39m\u001b[90m 23 |\u001b[39m expect(errorMessage)\u001b[33m.\u001b[39mtoEqual(\u001b[32m\"Test\"\u001b[39m)\u001b[33m;\u001b[39m\n \u001b[90m |\u001b[39m \u001b[31m\u001b[1m^\u001b[22m\u001b[39m\n \u001b[90m 24 |\u001b[39m })\u001b[33m;\u001b[39m\n \u001b[90m 25 |\u001b[39m })\u001b[33m;\u001b[39m\n \u001b[90m 26 |\u001b[39m\u001b[0m"}]
Expected behavior Expected: Test Received: "Incorrect username or password"
Screenshots attached
Desktop (please complete the following information): OS: iOS (MacBook Air) Running tests in Visual Studio Code Terminal playwright-xray version: ^0.6.5 @playwright/test: ^1.48.1 @types/node: ^22.7.9
Additional context Add any other context about the problem here.