allure-js
allure-js copied to clipboard
Mocha parallel mode and Allure API
Describe the bug We have a problem related to mocha parallel mode for a long time, there is some related issues in the repository: #485, #486.
To Reproduce Steps to reproduce the behavior:
- Use allure mocha reporter in parallel mode
- Try to call any allure API method such as label
- You'll see an error in console
Expected behavior We should be able to use Allure API with mocha in parallel mode.
Additional context
At this moment, the problem can't be solved because mocha parallel mode implementation. The running uses workerpool
module, what doesn't work with plain node IPC messages. Additionally, mocha doesn't provide any way to send messages from tests to the reporter, what works in the main thread, so we can't do anything at this moment to make both parts work correctly.
As temporal solution, I suggest to use single thread mode, if you need Allure API.
All the updates about the problem I'll post here, in the issue.