allure-js
allure-js copied to clipboard
TypeError: allure.label is not a function
Describe the bug Getting an error when parallel mode is on while using Mocha
To Reproduce Steps to reproduce the behavior:
- Set parallel mode to true in mocha.rc config or use "--parallel" flag
- Run the tests
- Tests fail due to the following error: Uncaught TypeError: hook.error is not a function
Expected behavior The tests should run successfully in parallel mode with Mocha allure reporter
Screenshots
Additional context the following version packages are used: "allure-mocha": "^2.0.0-beta.19", "mocha": "^9.2.1"
Could you please share more code or provide a repo, where would be possible to reproduce the problem?
Uploading lmru--chords--functional-tests2.zip… Sure, here is a sample project
@lamartire did you manage to check it out?
example-js-allure.zip -- one more example
Sorry guys, still working on the the solution
Nice, please let me know in case there is an update, thanks
Sorry for the long delay, but at this moment we're a bit paralyzed due parallel mode nuances. I've opened a PR (mochajs/mocha#4922) to mocha which provides required changes to restore back labels functionality, but I haven't yet got any response from them. Let's wait for the merge.
any update on this? I'm having the same issue
3.0.0-beta.1 introduced support for parallel mode
The issue has been fixed in 3.0.0-beta.1. If anyone still struggles with using Allure API in parallel mode, feel free to open a new issue or post an update here.