1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-09-23 03:22:50 +02:00
bitwarden-browser/libs/common
Matt Gibson 5b5c165e10
[PM-8847] Delay browser local storage operations during reseed (#9536)
* Define matchers to test promise fulfillment

These are useful for validating that promises depend on other events prior to fulfilling.

* Expose custom matchers to jest projects

Team-specific projects are not touched here to try and reduce review burden.

* Block browser local operations awaiting reseed

This should closes a narrow race condition resulting from storage operations during a reseed event.

* Import from barrel file

This might fix the failing test, but I'm not sure _why_

* Document helper methods

* Validate as few properties as possible per test

* Simplify expected value representation

* Allow waiting in promise matchers

* Specify resolution times in promise orchestration tests.

* Test behavior triggering multiple reseeds.

* Fix typo

* Avoid testing implementation details

* Clear reseed on startup

in case a previous process was aborted in the middle of a reseed.

* Correct formatting
2024-07-19 16:12:29 -04:00
..
spec [PM-8847] Delay browser local storage operations during reseed (#9536) 2024-07-19 16:12:29 -04:00
src [PM-9869] Create SendFormContainer (#10147) 2024-07-19 21:17:52 +02:00
custom-matchers.d.ts [PM-8847] Delay browser local storage operations during reseed (#9536) 2024-07-19 16:12:29 -04:00
jest.config.js [PM-2328] Fix jest deprecations (#5483) 2023-05-22 20:19:16 +02:00
package.json chore(deps): update dependency rimraf to v5 (#5468) 2023-05-19 14:23:44 +02:00
test.setup.ts [PM-8847] Delay browser local storage operations during reseed (#9536) 2024-07-19 16:12:29 -04:00
tsconfig.json Fix failing crypto tests (#5948) 2023-08-04 02:13:33 +00:00
tsconfig.spec.json [EC-423] Fix unit tests (#3265) 2022-08-11 11:35:08 +10:00