Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flaky test for Mocha extra reporters #1206

Open
delatrie opened this issue Dec 5, 2024 · 0 comments
Open

Flaky test for Mocha extra reporters #1206

delatrie opened this issue Dec 5, 2024 · 0 comments
Labels
theme:mocha Mocha related issue type:bug Something isn't working

Comments

@delatrie
Copy link
Collaborator

delatrie commented Dec 5, 2024

From https://github.com/allure-framework/allure-js/actions/runs/12118482707/job/33783055229#step:7:3207:

[allure-mocha]: ⎯⎯⎯⎯⎯⎯⎯ Failed Tests 1 ⎯⎯⎯⎯⎯⎯⎯
[allure-mocha]: 
[allure-mocha]:  FAIL  test/spec/framework/extraReporters.test.ts > extra reporters > two entries > first entry has options
[allure-mocha]: AssertionError: expected [ Array(1) ] to deeply equal ArrayContaining{…}
[allure-mocha]: 
[allure-mocha]: - Expected
[allure-mocha]: + Received
[allure-mocha]: 
[allure-mocha]: - ArrayContaining [
[allure-mocha]: -   StringMatching /^<testsuite/,
[allure-mocha]: -   StringMatching /^<testcase/,
[allure-mocha]: -   StringMatching /testsuite>\s*$/,
[allure-mocha]: + Array [
[allure-mocha]: +   "<testsuite name=\"Mocha Tests\" tests=\"1\" failures=\"0\" errors=\"0\" skipped=\"0\" timestamp=\"Mon, 02 Dec 2024 11:53:19 GMT\" time=\"0.438\">
[allure-mocha]: + <testcase classname=\"foo\" name=\"a test in a suite\" file=\"/home/runner/work/allure-js/allure-js/packages/allure-mocha/test/fixtures/10f79159-a8a0-448f-b838-a288000532bf/plain-mocha/testInSuite.spec.mjs\" time=\"0\"/>
[allure-mocha]: + </testsuite>
[allure-mocha]: + ",
[allure-mocha]:   ]
[allure-mocha]: 
[allure-mocha]:  ❯ test/spec/framework/extraReporters.test.ts:110:22
[allure-mocha]:     108| 
[allure-mocha]:     109|       expect(tests).toEqual([expect.objectContaining({ name: "a test i…
[allure-mocha]:     110|       expect(stdout).toEqual(
[allure-mocha]:        |                      ^
[allure-mocha]:     111|         expect.arrayContaining([
[allure-mocha]:     112|           expect.stringMatching(/^<testsuite/),
[allure-mocha]: 
[allure-mocha]: ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/1]⎯
[allure-mocha]: 
[allure-mocha]:  Test Files  1 failed | 34 passed (35)
[allure-mocha]:       Tests  1 failed | 175 passed (176)
[allure-mocha]: Type Errors  no errors
[allure-mocha]:    Start at  11:53:13
[allure-mocha]:    Duration  63.82s (transform 382ms, setup 1.95s, collect 342ms, tests 46.78s, environment 7ms, prepare 4.07s)
[allure-mocha]: 
[allure-mocha]: ERROR: "test:runner-parallel" exited with 1.

The test depends on a specific output, which is not guaranteed in all cases.

@delatrie delatrie added type:bug Something isn't working theme:mocha Mocha related issue labels Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
theme:mocha Mocha related issue type:bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant