-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
parallel mode: enable custom worker reporters and object references #4409
Conversation
@boneskull Great! I've just tried it with the example from #4403, and now |
de5bdfc
to
bf91eac
Compare
@segrey So this looks good as-is? I'll wrap it up then. |
8211cd6
to
169593a
Compare
aaa8424
to
87bb39b
Compare
@segrey if you can share it, I'd love to see the implementation you've built with this |
87bb39b
to
6f8a242
Compare
@mochajs/core please review, otherwise will merge in next couple days |
@boneskull Please see mocha-intellij.zip. Main reporter is There are some minor questions left in #4403 (comment). Would be great if you could take a look. |
- `Suite`s, `Test`s, etc., now have unique identifiers which can optionally be used to re-created object references by a reporter which opts-in to the behavior - A reporter can swap out the worker’s reporter for a custom one - fixed an issue in rollup config causing weird problems - changed how we define `global.Mocha` in `browser-entry.js` (tangential) - removed `object.assign` polyfill (tangential) - renamed misnamed `buffered-runner.spec.js` to `parallel-buffered-runner.spec.js` - added a few unit tests - refactored some tests; mainly modernizing some syntax
Signed-off-by: Christopher Hiller <boneskull@boneskull.com>
the only time this should happen in a non-unit-test context is when a mocha developer introduces a bug also fix a `rewiremock` call in `ParallelBuffered` reporter tests
16d7960
to
1288205
Compare
@segrey This has landed... will be released in next version which will be v8.2.0 |
@segrey please see this one. It will allow a reporter to call
runner.linkPartialObjects(true)
(see example in docstring) to replace duplicated deserialized objects with references. The objects themselves are still shallow, but if there's a particular property you need that is missing, we can likely add it.I didn't test this too hard, but please let me know if this would help. I'm not sure about the missing
root
prop issue...Ref: #4403
global.Mocha
inbrowser-entry.js
(tangential)object.assign
polyfill (tangential)buffered-runner.spec.js
toparallel-buffered-runner.spec.js