1ae9b6fa89852eaf40249344f5a0fbc0cdb5f8a5
The 'Bridge not ready' test was creating a real iframe in jsdom via the unmocked createBridge method. The iframe's onload event could fire asynchronously at non-deterministic times, causing the pending createBridge promise to resolve during a subsequent test. When the old async executor resumed, it interfered with the currently running test, causing all tests that use sendCommandToTrezorFrame to fail with BridgeNotReady. Fix by mocking createBridge in the 'Bridge not ready' test to use a lightweight div element (to satisfy hasBridgeCreated) and return a never-resolving promise, avoiding jsdom iframe side effects while preserving the test's intent. Resolves https://github.com/brave/brave-browser/issues/53483
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
Brave Core
Brave Core is a set of changes, APIs, and scripts used for customizing Chromium to make the Brave browser. Please also check https://github.com/brave/brave-browser
Follow @brave on Twitter for important announcements.
Resources
Community
You can ask questions and interact with the community in the following locations:
- Brave Community
communitychannel on Brave Software's Slack
Languages
C++
36.9%
HTML
31.6%
Swift
9.4%
TypeScript
9%
Java
4.8%
Other
8.1%