@metamask/snaps-jest 8.3.1 → 8.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -1
- package/dist/internals/environment.d.cts +1 -1
- package/dist/internals/environment.d.mts +1 -1
- package/dist/internals/simulation/store/mocks.d.cts +3 -3
- package/dist/internals/simulation/store/mocks.d.mts +3 -3
- package/dist/internals/simulation/store/notifications.d.cts +3 -3
- package/dist/internals/simulation/store/notifications.d.mts +3 -3
- package/dist/internals/simulation/store/state.d.cts +6 -6
- package/dist/internals/simulation/store/state.d.mts +6 -6
- package/dist/internals/simulation/store/store.d.cts +4 -4
- package/dist/internals/simulation/store/store.d.mts +4 -4
- package/dist/internals/simulation/store/ui.d.cts +3 -3
- package/dist/internals/simulation/store/ui.d.mts +3 -3
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [8.3.2]
|
|
10
|
+
### Fixed
|
|
11
|
+
- Fix invalid types in type declaration in some cases ([#2714](https://github.com/MetaMask/snaps/pull/2714))
|
|
12
|
+
|
|
9
13
|
## [8.3.1]
|
|
10
14
|
### Fixed
|
|
11
15
|
- Fix ESM version of the package ([#2682](https://github.com/MetaMask/snaps/pull/2682))
|
|
@@ -189,7 +193,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
189
193
|
- The version of the package no longer needs to match the version of all other
|
|
190
194
|
MetaMask Snaps packages.
|
|
191
195
|
|
|
192
|
-
[Unreleased]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-jest@8.3.
|
|
196
|
+
[Unreleased]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-jest@8.3.2...HEAD
|
|
197
|
+
[8.3.2]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-jest@8.3.1...@metamask/snaps-jest@8.3.2
|
|
193
198
|
[8.3.1]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-jest@8.3.0...@metamask/snaps-jest@8.3.1
|
|
194
199
|
[8.3.0]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-jest@8.2.0...@metamask/snaps-jest@8.3.0
|
|
195
200
|
[8.2.0]: https://github.com/MetaMask/snaps/compare/@metamask/snaps-jest@8.1.3...@metamask/snaps-jest@8.2.0
|
|
@@ -25,9 +25,9 @@ export declare const getJsonRpcMocks: (state: ApplicationState) => Record<string
|
|
|
25
25
|
*/
|
|
26
26
|
export declare const getJsonRpcMock: ((state: {
|
|
27
27
|
mocks: MocksState;
|
|
28
|
-
notifications: import("./notifications").NotificationsState;
|
|
29
|
-
state: import("./state").State;
|
|
30
|
-
ui: import("./ui").UiState;
|
|
28
|
+
notifications: import("./notifications.cjs").NotificationsState;
|
|
29
|
+
state: import("./state.cjs").State;
|
|
30
|
+
ui: import("./ui.cjs").UiState;
|
|
31
31
|
}, method: string) => Json) & import("reselect").OutputSelectorFields<(args_0: Record<string, Json>, args_1: string) => Json, {
|
|
32
32
|
clearCache: () => void;
|
|
33
33
|
}> & {
|
|
@@ -25,9 +25,9 @@ export declare const getJsonRpcMocks: (state: ApplicationState) => Record<string
|
|
|
25
25
|
*/
|
|
26
26
|
export declare const getJsonRpcMock: ((state: {
|
|
27
27
|
mocks: MocksState;
|
|
28
|
-
notifications: import("./notifications").NotificationsState;
|
|
29
|
-
state: import("./state").State;
|
|
30
|
-
ui: import("./ui").UiState;
|
|
28
|
+
notifications: import("./notifications.mjs").NotificationsState;
|
|
29
|
+
state: import("./state.mjs").State;
|
|
30
|
+
ui: import("./ui.mjs").UiState;
|
|
31
31
|
}, method: string) => Json) & import("reselect").OutputSelectorFields<(args_0: Record<string, Json>, args_1: string) => Json, {
|
|
32
32
|
clearCache: () => void;
|
|
33
33
|
}> & {
|
|
@@ -33,10 +33,10 @@ export declare const addNotification: import("@reduxjs/toolkit").ActionCreatorWi
|
|
|
33
33
|
* @returns An array of notifications.
|
|
34
34
|
*/
|
|
35
35
|
export declare const getNotifications: ((state: {
|
|
36
|
-
mocks: import("./mocks").MocksState;
|
|
36
|
+
mocks: import("./mocks.cjs").MocksState;
|
|
37
37
|
notifications: NotificationsState;
|
|
38
|
-
state: import("./state").State;
|
|
39
|
-
ui: import("./ui").UiState;
|
|
38
|
+
state: import("./state.cjs").State;
|
|
39
|
+
ui: import("./ui.cjs").UiState;
|
|
40
40
|
}) => Notification[]) & import("reselect").OutputSelectorFields<(args_0: NotificationsState) => Notification[], {
|
|
41
41
|
clearCache: () => void;
|
|
42
42
|
}> & {
|
|
@@ -33,10 +33,10 @@ export declare const addNotification: import("@reduxjs/toolkit").ActionCreatorWi
|
|
|
33
33
|
* @returns An array of notifications.
|
|
34
34
|
*/
|
|
35
35
|
export declare const getNotifications: ((state: {
|
|
36
|
-
mocks: import("./mocks").MocksState;
|
|
36
|
+
mocks: import("./mocks.mjs").MocksState;
|
|
37
37
|
notifications: NotificationsState;
|
|
38
|
-
state: import("./state").State;
|
|
39
|
-
ui: import("./ui").UiState;
|
|
38
|
+
state: import("./state.mjs").State;
|
|
39
|
+
ui: import("./ui.mjs").UiState;
|
|
40
40
|
}) => Notification[]) & import("reselect").OutputSelectorFields<(args_0: NotificationsState) => Notification[], {
|
|
41
41
|
clearCache: () => void;
|
|
42
42
|
}> & {
|
|
@@ -39,15 +39,15 @@ export declare const setState: import("@reduxjs/toolkit").ActionCreatorWithPaylo
|
|
|
39
39
|
* @returns A selector that returns the state.
|
|
40
40
|
*/
|
|
41
41
|
export declare function getState(encrypted: boolean): ((state: {
|
|
42
|
-
mocks: import("./mocks").MocksState;
|
|
43
|
-
notifications: import("./notifications").NotificationsState;
|
|
42
|
+
mocks: import("./mocks.cjs").MocksState;
|
|
43
|
+
notifications: import("./notifications.cjs").NotificationsState;
|
|
44
44
|
state: State;
|
|
45
|
-
ui: import("./ui").UiState;
|
|
45
|
+
ui: import("./ui.cjs").UiState;
|
|
46
46
|
}) => string | null) & import("reselect").OutputSelectorFields<(args_0: {
|
|
47
|
-
mocks: import("./mocks").MocksState;
|
|
48
|
-
notifications: import("./notifications").NotificationsState;
|
|
47
|
+
mocks: import("./mocks.cjs").MocksState;
|
|
48
|
+
notifications: import("./notifications.cjs").NotificationsState;
|
|
49
49
|
state: State;
|
|
50
|
-
ui: import("./ui").UiState;
|
|
50
|
+
ui: import("./ui.cjs").UiState;
|
|
51
51
|
}) => string | null, {
|
|
52
52
|
clearCache: () => void;
|
|
53
53
|
}> & {
|
|
@@ -39,15 +39,15 @@ export declare const setState: import("@reduxjs/toolkit").ActionCreatorWithPaylo
|
|
|
39
39
|
* @returns A selector that returns the state.
|
|
40
40
|
*/
|
|
41
41
|
export declare function getState(encrypted: boolean): ((state: {
|
|
42
|
-
mocks: import("./mocks").MocksState;
|
|
43
|
-
notifications: import("./notifications").NotificationsState;
|
|
42
|
+
mocks: import("./mocks.mjs").MocksState;
|
|
43
|
+
notifications: import("./notifications.mjs").NotificationsState;
|
|
44
44
|
state: State;
|
|
45
|
-
ui: import("./ui").UiState;
|
|
45
|
+
ui: import("./ui.mjs").UiState;
|
|
46
46
|
}) => string | null) & import("reselect").OutputSelectorFields<(args_0: {
|
|
47
|
-
mocks: import("./mocks").MocksState;
|
|
48
|
-
notifications: import("./notifications").NotificationsState;
|
|
47
|
+
mocks: import("./mocks.mjs").MocksState;
|
|
48
|
+
notifications: import("./notifications.mjs").NotificationsState;
|
|
49
49
|
state: State;
|
|
50
|
-
ui: import("./ui").UiState;
|
|
50
|
+
ui: import("./ui.mjs").UiState;
|
|
51
51
|
}) => string | null, {
|
|
52
52
|
clearCache: () => void;
|
|
53
53
|
}> & {
|
|
@@ -9,10 +9,10 @@ import type { SimulationOptions } from "../options.cjs";
|
|
|
9
9
|
*/
|
|
10
10
|
export declare function createStore({ state, unencryptedState }: SimulationOptions): {
|
|
11
11
|
store: import("@reduxjs/toolkit/dist/configureStore").ToolkitStore<{
|
|
12
|
-
mocks: import("./mocks").MocksState;
|
|
13
|
-
notifications: import("./notifications").NotificationsState;
|
|
14
|
-
state: import("./state").State;
|
|
15
|
-
ui: import("./ui").UiState;
|
|
12
|
+
mocks: import("./mocks.cjs").MocksState;
|
|
13
|
+
notifications: import("./notifications.cjs").NotificationsState;
|
|
14
|
+
state: import("./state.cjs").State;
|
|
15
|
+
ui: import("./ui.cjs").UiState;
|
|
16
16
|
}, import("redux").AnyAction, import("@reduxjs/toolkit").MiddlewareArray<[import("redux-saga").SagaMiddleware<object>]>>;
|
|
17
17
|
runSaga: <S extends import("redux-saga").Saga>(saga: S, ...args: Parameters<S>) => import("redux-saga").Task<any>;
|
|
18
18
|
};
|
|
@@ -9,10 +9,10 @@ import type { SimulationOptions } from "../options.mjs";
|
|
|
9
9
|
*/
|
|
10
10
|
export declare function createStore({ state, unencryptedState }: SimulationOptions): {
|
|
11
11
|
store: import("@reduxjs/toolkit/dist/configureStore").ToolkitStore<{
|
|
12
|
-
mocks: import("./mocks").MocksState;
|
|
13
|
-
notifications: import("./notifications").NotificationsState;
|
|
14
|
-
state: import("./state").State;
|
|
15
|
-
ui: import("./ui").UiState;
|
|
12
|
+
mocks: import("./mocks.mjs").MocksState;
|
|
13
|
+
notifications: import("./notifications.mjs").NotificationsState;
|
|
14
|
+
state: import("./state.mjs").State;
|
|
15
|
+
ui: import("./ui.mjs").UiState;
|
|
16
16
|
}, import("redux").AnyAction, import("@reduxjs/toolkit").MiddlewareArray<[import("redux-saga").SagaMiddleware<object>]>>;
|
|
17
17
|
runSaga: <S extends import("redux-saga").Saga>(saga: S, ...args: Parameters<S>) => import("redux-saga").Task<any>;
|
|
18
18
|
};
|
|
@@ -15,9 +15,9 @@ export declare const uiSlice: import("@reduxjs/toolkit").Slice<UiState, {
|
|
|
15
15
|
export declare const resolveInterface: import("@reduxjs/toolkit").ActionCreatorWithNonInferrablePayload<string>;
|
|
16
16
|
export declare const setInterface: import("@reduxjs/toolkit").ActionCreatorWithPayload<Interface, "ui/setInterface">, closeInterface: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"ui/closeInterface">;
|
|
17
17
|
export declare const getCurrentInterface: ((state: {
|
|
18
|
-
mocks: import("./mocks").MocksState;
|
|
19
|
-
notifications: import("./notifications").NotificationsState;
|
|
20
|
-
state: import("./state").State;
|
|
18
|
+
mocks: import("./mocks.cjs").MocksState;
|
|
19
|
+
notifications: import("./notifications.cjs").NotificationsState;
|
|
20
|
+
state: import("./state.cjs").State;
|
|
21
21
|
ui: UiState;
|
|
22
22
|
}) => Interface | null | undefined) & import("reselect").OutputSelectorFields<(args_0: UiState) => Interface | null | undefined, {
|
|
23
23
|
clearCache: () => void;
|
|
@@ -15,9 +15,9 @@ export declare const uiSlice: import("@reduxjs/toolkit").Slice<UiState, {
|
|
|
15
15
|
export declare const resolveInterface: import("@reduxjs/toolkit").ActionCreatorWithNonInferrablePayload<string>;
|
|
16
16
|
export declare const setInterface: import("@reduxjs/toolkit").ActionCreatorWithPayload<Interface, "ui/setInterface">, closeInterface: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"ui/closeInterface">;
|
|
17
17
|
export declare const getCurrentInterface: ((state: {
|
|
18
|
-
mocks: import("./mocks").MocksState;
|
|
19
|
-
notifications: import("./notifications").NotificationsState;
|
|
20
|
-
state: import("./state").State;
|
|
18
|
+
mocks: import("./mocks.mjs").MocksState;
|
|
19
|
+
notifications: import("./notifications.mjs").NotificationsState;
|
|
20
|
+
state: import("./state.mjs").State;
|
|
21
21
|
ui: UiState;
|
|
22
22
|
}) => Interface | null | undefined) & import("reselect").OutputSelectorFields<(args_0: UiState) => Interface | null | undefined, {
|
|
23
23
|
clearCache: () => void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@metamask/snaps-jest",
|
|
3
|
-
"version": "8.3.
|
|
3
|
+
"version": "8.3.2",
|
|
4
4
|
"description": "A Jest preset for end-to-end testing MetaMask Snaps, including a Jest environment, and a set of Jest matchers.",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"exports": {
|
|
@@ -49,11 +49,11 @@
|
|
|
49
49
|
"@metamask/key-tree": "^9.1.2",
|
|
50
50
|
"@metamask/permission-controller": "^11.0.0",
|
|
51
51
|
"@metamask/phishing-controller": "^12.0.2",
|
|
52
|
-
"@metamask/snaps-controllers": "^9.
|
|
53
|
-
"@metamask/snaps-execution-environments": "^6.7.
|
|
54
|
-
"@metamask/snaps-rpc-methods": "^11.1.
|
|
55
|
-
"@metamask/snaps-sdk": "^6.
|
|
56
|
-
"@metamask/snaps-utils": "^8.1.
|
|
52
|
+
"@metamask/snaps-controllers": "^9.7.0",
|
|
53
|
+
"@metamask/snaps-execution-environments": "^6.7.1",
|
|
54
|
+
"@metamask/snaps-rpc-methods": "^11.1.1",
|
|
55
|
+
"@metamask/snaps-sdk": "^6.5.0",
|
|
56
|
+
"@metamask/snaps-utils": "^8.1.1",
|
|
57
57
|
"@metamask/superstruct": "^3.1.0",
|
|
58
58
|
"@metamask/utils": "^9.2.1",
|
|
59
59
|
"@reduxjs/toolkit": "^1.9.5",
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
"@metamask/eslint-config-typescript": "^12.1.0",
|
|
76
76
|
"@swc/core": "1.3.78",
|
|
77
77
|
"@swc/jest": "^0.2.26",
|
|
78
|
-
"@ts-bridge/cli": "^0.
|
|
78
|
+
"@ts-bridge/cli": "^0.5.1",
|
|
79
79
|
"@types/jest": "^27.5.1",
|
|
80
80
|
"@types/mime": "^3.0.0",
|
|
81
81
|
"@types/semver": "^7.5.0",
|