We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
await wrapper.findComponent({ ref: "videoScaleToggle" }).trigger("click");
or
await wrapper.findComponent({ ref: "videoScaleToggle" }).trigger("change");]
these dont work in jest
The text was updated successfully, but these errors were encountered:
For anyone else reaching this issue with the same problem: To be able to trigger an event on the toggle button, I just attached a selector to it
<toggle-button data-test-id="toggle" />
While inspecting the HTML produced, I noticed that the selector was being attached to a <label> which wraps the <input type="checkbox">. Something lke
<label>
<input type="checkbox">
<label data-test-id="toggle"> <input type="checkbox" /> </label>
So I updated the toggle value by calling
wrapper.find(`[data-test-id="toggle"] input`).setChecked(true)
Sorry, something went wrong.
No branches or pull requests
await wrapper.findComponent({ ref: "videoScaleToggle" }).trigger("click");
or
await wrapper.findComponent({ ref: "videoScaleToggle" }).trigger("change");]
these dont work in jest
The text was updated successfully, but these errors were encountered: