Commit 6dced9e
committed
test: Avoid test failures from unlocking undefined stores
With the previous mock, the entire `@wordpress/data` module was
replaced. This led to emptying utilities like `createReduxStore`. This
resulted in other `@wordpress` modules throwing errors when attempting
to act upon stores.
```
FAIL src/utils/editor.test.jsx [ src/utils/editor.test.jsx ]
Error: Cannot unlock an undefined object.
❯ unlock node_modules/@wordpress/private-apis/src/implementation.ts:186:9
❯ node_modules/@wordpress/blocks/src/store/index.js:31:1
❯ node_modules/@wordpress/blocks/src/index.js:11:1
```1 parent 191d555 commit 6dced9e
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| |||
0 commit comments