-
-
Notifications
You must be signed in to change notification settings - Fork 6.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
test: test ModuleRunnerTransport
invoke
API
#18865
test: test ModuleRunnerTransport
invoke
API
#18865
Conversation
fcbd6db
to
8c6af6e
Compare
8c6af6e
to
bf534db
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks 🙏
packages/vite/src/node/ssr/runtime/__tests__/server-worker-runner.invoke.spec.ts
Outdated
Show resolved
Hide resolved
use different broadcast channel name Co-authored-by: sapphi-red <49056869+sapphi-red@users.noreply.github.com>
use birpc to avoid relying on internal structure of invoke
simplify and improve tests
remove unnecessary assertion
simplify worker code
remove extra finally
Thanks for the change 💚 While trying this PR locally, I found a bug in the previous PR and made a fix for it (#18876). 72ee49b: set the return value of invoke on the main thread side as it will be called from the worker side, also made the successful case to use The tests should pass after #18876 is merged. |
Thanks a lot for the changes @sapphi-red 🙏 |
This PR is adding a test for the
invoke
method of theModuleRunnerTransport
Followup from: #18851