mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-22 09:23:21 +01:00
Enable snaps in stable (#19134)
* Enable Snaps feature flag in stable * Run snaps E2Es in stable * Fix CI config indentation * Fix CI paths * Update LavaMoat policies * Update iframe URL * Exclude some tests from running in stable e2e * Disable another test on stable * Bump to 1.0.1 * Fix config.yml issue due to staleness * Stop running newly added test * Update snapshots used for E2E * Use shallow-git-clone
This commit is contained in:
parent
5e617ce808
commit
8f178bcc26
@ -152,8 +152,14 @@ workflows:
|
||||
- prep-build-test
|
||||
- test-e2e-chrome-snaps:
|
||||
requires:
|
||||
- prep-build-test-flask
|
||||
- prep-build-test
|
||||
- test-e2e-firefox-snaps:
|
||||
requires:
|
||||
- prep-build-test
|
||||
- test-e2e-chrome-snaps-flask:
|
||||
requires:
|
||||
- prep-build-test-flask
|
||||
- test-e2e-firefox-snaps-flask:
|
||||
requires:
|
||||
- prep-build-test-flask
|
||||
- test-e2e-chrome-mv3:
|
||||
@ -847,6 +853,80 @@ jobs:
|
||||
path: test/test-results/e2e.xml
|
||||
|
||||
test-e2e-firefox-snaps:
|
||||
executor: node-browsers
|
||||
parallelism: 4
|
||||
steps:
|
||||
- run: *shallow-git-clone
|
||||
- run:
|
||||
name: Install Firefox
|
||||
command: ./.circleci/scripts/firefox-install.sh
|
||||
- attach_workspace:
|
||||
at: .
|
||||
- run:
|
||||
name: Move test build to dist
|
||||
command: mv ./dist-test ./dist
|
||||
- run:
|
||||
name: Move test zips to builds
|
||||
command: mv ./builds-test ./builds
|
||||
- run:
|
||||
name: test:e2e:firefox:snaps
|
||||
command: |
|
||||
if .circleci/scripts/test-run-e2e.sh
|
||||
then
|
||||
yarn test:e2e:firefox:snaps --retries 2 --debug --build-type=main
|
||||
fi
|
||||
no_output_timeout: 20m
|
||||
- run:
|
||||
name: Merge JUnit report
|
||||
command: |
|
||||
if [ "$(ls -A test/test-results/e2e)" ]; then
|
||||
yarn test:e2e:report
|
||||
fi
|
||||
when: always
|
||||
- store_artifacts:
|
||||
path: test-artifacts
|
||||
destination: test-artifacts
|
||||
- store_test_results:
|
||||
path: test/test-results/e2e.xml
|
||||
|
||||
test-e2e-chrome-snaps:
|
||||
executor: node-browsers
|
||||
parallelism: 4
|
||||
steps:
|
||||
- run: *shallow-git-clone
|
||||
- run:
|
||||
name: Re-Install Chrome
|
||||
command: ./.circleci/scripts/chrome-install.sh
|
||||
- attach_workspace:
|
||||
at: .
|
||||
- run:
|
||||
name: Move test build to dist
|
||||
command: mv ./dist-test ./dist
|
||||
- run:
|
||||
name: Move test zips to builds
|
||||
command: mv ./builds-test ./builds
|
||||
- run:
|
||||
name: test:e2e:chrome:snaps
|
||||
command: |
|
||||
if .circleci/scripts/test-run-e2e.sh
|
||||
then
|
||||
yarn test:e2e:chrome:snaps --retries 2 --debug --build-type=main
|
||||
fi
|
||||
no_output_timeout: 20m
|
||||
- run:
|
||||
name: Merge JUnit report
|
||||
command: |
|
||||
if [ "$(ls -A test/test-results/e2e)" ]; then
|
||||
yarn test:e2e:report
|
||||
fi
|
||||
when: always
|
||||
- store_artifacts:
|
||||
path: test-artifacts
|
||||
destination: test-artifacts
|
||||
- store_test_results:
|
||||
path: test/test-results/e2e.xml
|
||||
|
||||
test-e2e-firefox-snaps-flask:
|
||||
executor: node-browsers
|
||||
parallelism: 4
|
||||
steps:
|
||||
@ -883,7 +963,7 @@ jobs:
|
||||
- store_test_results:
|
||||
path: test/test-results/e2e.xml
|
||||
|
||||
test-e2e-chrome-snaps:
|
||||
test-e2e-chrome-snaps-flask:
|
||||
executor: node-browsers
|
||||
parallelism: 4
|
||||
steps:
|
||||
|
@ -16,12 +16,16 @@ buildTypes:
|
||||
main:
|
||||
features:
|
||||
- build-main
|
||||
- snaps
|
||||
# Additional env variables that are specific to this build
|
||||
env:
|
||||
- INFURA_PROD_PROJECT_ID
|
||||
- SEGMENT_PROD_WRITE_KEY
|
||||
- INFURA_ENV_KEY_REF: INFURA_PROD_PROJECT_ID
|
||||
- SEGMENT_WRITE_KEY_REF: SEGMENT_PROD_WRITE_KEY
|
||||
- ALLOW_LOCAL_SNAPS: false
|
||||
- REQUIRE_SNAPS_ALLOWLIST: true
|
||||
- IFRAME_EXECUTION_ENVIRONMENT_URL: https://execution.metamask.io/1.0.1/index.html
|
||||
# Main build uses the default browser manifest
|
||||
manifestOverrides: false
|
||||
|
||||
|
@ -1751,6 +1751,13 @@
|
||||
"browserify>events": true
|
||||
}
|
||||
},
|
||||
"@metamask/notification-controller": {
|
||||
"packages": {
|
||||
"@metamask/base-controller": true,
|
||||
"@metamask/notification-controller>nanoid": true,
|
||||
"@metamask/utils": true
|
||||
}
|
||||
},
|
||||
"@metamask/notification-controller>nanoid": {
|
||||
"globals": {
|
||||
"crypto.getRandomValues": true
|
||||
@ -1807,6 +1814,52 @@
|
||||
"eslint>optionator>fast-levenshtein": true
|
||||
}
|
||||
},
|
||||
"@metamask/post-message-stream": {
|
||||
"globals": {
|
||||
"MessageEvent.prototype": true,
|
||||
"WorkerGlobalScope": true,
|
||||
"addEventListener": true,
|
||||
"browser": true,
|
||||
"chrome": true,
|
||||
"location.origin": true,
|
||||
"postMessage": true,
|
||||
"removeEventListener": true
|
||||
},
|
||||
"packages": {
|
||||
"@metamask/post-message-stream>readable-stream": true,
|
||||
"@metamask/utils": true
|
||||
}
|
||||
},
|
||||
"@metamask/post-message-stream>readable-stream": {
|
||||
"packages": {
|
||||
"@metamask/post-message-stream>readable-stream>process-nextick-args": true,
|
||||
"@metamask/post-message-stream>readable-stream>safe-buffer": true,
|
||||
"@metamask/post-message-stream>readable-stream>string_decoder": true,
|
||||
"browserify>browser-resolve": true,
|
||||
"browserify>events": true,
|
||||
"browserify>process": true,
|
||||
"browserify>timers-browserify": true,
|
||||
"pumpify>inherits": true,
|
||||
"readable-stream>core-util-is": true,
|
||||
"readable-stream>isarray": true,
|
||||
"readable-stream>util-deprecate": true
|
||||
}
|
||||
},
|
||||
"@metamask/post-message-stream>readable-stream>process-nextick-args": {
|
||||
"packages": {
|
||||
"browserify>process": true
|
||||
}
|
||||
},
|
||||
"@metamask/post-message-stream>readable-stream>safe-buffer": {
|
||||
"packages": {
|
||||
"browserify>buffer": true
|
||||
}
|
||||
},
|
||||
"@metamask/post-message-stream>readable-stream>string_decoder": {
|
||||
"packages": {
|
||||
"@metamask/post-message-stream>readable-stream>safe-buffer": true
|
||||
}
|
||||
},
|
||||
"@metamask/ppom-validator>elliptic": {
|
||||
"packages": {
|
||||
"@metamask/ppom-validator>elliptic>brorand": true,
|
||||
@ -1834,6 +1887,25 @@
|
||||
"ethereumjs-util>ethereum-cryptography>hash.js": true
|
||||
}
|
||||
},
|
||||
"@metamask/providers>@metamask/object-multiplex": {
|
||||
"globals": {
|
||||
"console.warn": true
|
||||
},
|
||||
"packages": {
|
||||
"end-of-stream": true,
|
||||
"pump>once": true,
|
||||
"readable-stream": true
|
||||
}
|
||||
},
|
||||
"@metamask/rate-limit-controller": {
|
||||
"globals": {
|
||||
"setTimeout": true
|
||||
},
|
||||
"packages": {
|
||||
"@metamask/base-controller": true,
|
||||
"eth-rpc-errors": true
|
||||
}
|
||||
},
|
||||
"@metamask/rpc-methods": {
|
||||
"packages": {
|
||||
"@metamask/browser-passworder": true,
|
||||
@ -1950,16 +2022,203 @@
|
||||
"define": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers": {
|
||||
"globals": {
|
||||
"URL": true,
|
||||
"chrome.offscreen.createDocument": true,
|
||||
"chrome.offscreen.hasDocument": true,
|
||||
"clearTimeout": true,
|
||||
"document.getElementById": true,
|
||||
"fetch.bind": true,
|
||||
"setTimeout": true
|
||||
},
|
||||
"packages": {
|
||||
"@metamask/base-controller": true,
|
||||
"@metamask/permission-controller": true,
|
||||
"@metamask/post-message-stream": true,
|
||||
"@metamask/providers>@metamask/object-multiplex": true,
|
||||
"@metamask/rpc-methods": true,
|
||||
"@metamask/snaps-controllers>@metamask/utils": true,
|
||||
"@metamask/snaps-controllers>@xstate/fsm": true,
|
||||
"@metamask/snaps-controllers>concat-stream": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe": true,
|
||||
"@metamask/snaps-controllers>nanoid": true,
|
||||
"@metamask/snaps-controllers>readable-web-to-node-stream": true,
|
||||
"@metamask/snaps-controllers>tar-stream": true,
|
||||
"@metamask/snaps-utils": true,
|
||||
"@metamask/snaps-utils>@metamask/snaps-registry": true,
|
||||
"eth-rpc-errors": true,
|
||||
"json-rpc-engine": true,
|
||||
"json-rpc-middleware-stream": true,
|
||||
"pump": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers-flask>nanoid": {
|
||||
"globals": {
|
||||
"crypto.getRandomValues": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>@metamask/utils": {
|
||||
"globals": {
|
||||
"TextDecoder": true,
|
||||
"TextEncoder": true
|
||||
},
|
||||
"packages": {
|
||||
"@metamask/key-tree>@noble/hashes": true,
|
||||
"browserify>buffer": true,
|
||||
"nock>debug": true,
|
||||
"semver": true,
|
||||
"superstruct": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>concat-stream": {
|
||||
"packages": {
|
||||
"@metamask/snaps-controllers>concat-stream>readable-stream": true,
|
||||
"browserify>buffer": true,
|
||||
"browserify>concat-stream>typedarray": true,
|
||||
"pumpify>inherits": true,
|
||||
"terser>source-map-support>buffer-from": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>concat-stream>readable-stream": {
|
||||
"packages": {
|
||||
"browserify>browser-resolve": true,
|
||||
"browserify>buffer": true,
|
||||
"browserify>events": true,
|
||||
"browserify>process": true,
|
||||
"browserify>string_decoder": true,
|
||||
"pumpify>inherits": true,
|
||||
"readable-stream>util-deprecate": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe": {
|
||||
"packages": {
|
||||
"@metamask/snaps-controllers>gunzip-maybe>browserify-zlib": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe>is-deflate": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe>is-gzip": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe>peek-stream": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe>pumpify": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe>through2": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>browserify-zlib": {
|
||||
"packages": {
|
||||
"@metamask/snaps-controllers>gunzip-maybe>browserify-zlib>pako": true,
|
||||
"browserify>assert": true,
|
||||
"browserify>buffer": true,
|
||||
"browserify>process": true,
|
||||
"browserify>util": true,
|
||||
"readable-stream": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>peek-stream": {
|
||||
"packages": {
|
||||
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>duplexify": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>through2": true,
|
||||
"browserify>buffer": true,
|
||||
"terser>source-map-support>buffer-from": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>duplexify": {
|
||||
"packages": {
|
||||
"browserify>buffer": true,
|
||||
"browserify>process": true,
|
||||
"duplexify>stream-shift": true,
|
||||
"end-of-stream": true,
|
||||
"pumpify>inherits": true,
|
||||
"readable-stream": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>peek-stream>through2": {
|
||||
"packages": {
|
||||
"browserify>process": true,
|
||||
"browserify>util": true,
|
||||
"readable-stream": true,
|
||||
"watchify>xtend": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>pumpify": {
|
||||
"packages": {
|
||||
"@metamask/snaps-controllers>gunzip-maybe>pumpify>duplexify": true,
|
||||
"@metamask/snaps-controllers>gunzip-maybe>pumpify>pump": true,
|
||||
"pumpify>inherits": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>pumpify>duplexify": {
|
||||
"packages": {
|
||||
"browserify>buffer": true,
|
||||
"browserify>process": true,
|
||||
"duplexify>stream-shift": true,
|
||||
"end-of-stream": true,
|
||||
"pumpify>inherits": true,
|
||||
"readable-stream": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>pumpify>pump": {
|
||||
"packages": {
|
||||
"browserify>browser-resolve": true,
|
||||
"end-of-stream": true,
|
||||
"pump>once": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>gunzip-maybe>through2": {
|
||||
"packages": {
|
||||
"browserify>process": true,
|
||||
"browserify>util": true,
|
||||
"readable-stream": true,
|
||||
"watchify>xtend": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>nanoid": {
|
||||
"globals": {
|
||||
"crypto.getRandomValues": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>readable-web-to-node-stream": {
|
||||
"packages": {
|
||||
"@metamask/snaps-controllers>readable-web-to-node-stream>readable-stream": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>readable-web-to-node-stream>readable-stream": {
|
||||
"packages": {
|
||||
"browserify>browser-resolve": true,
|
||||
"browserify>buffer": true,
|
||||
"browserify>events": true,
|
||||
"browserify>process": true,
|
||||
"browserify>string_decoder": true,
|
||||
"pumpify>inherits": true,
|
||||
"readable-stream>util-deprecate": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>tar-stream": {
|
||||
"packages": {
|
||||
"@metamask/snaps-controllers>tar-stream>fs-constants": true,
|
||||
"@metamask/snaps-controllers>tar-stream>readable-stream": true,
|
||||
"browserify>buffer": true,
|
||||
"browserify>process": true,
|
||||
"browserify>string_decoder": true,
|
||||
"browserify>util": true,
|
||||
"end-of-stream": true,
|
||||
"madge>ora>bl": true,
|
||||
"pumpify>inherits": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>tar-stream>fs-constants": {
|
||||
"packages": {
|
||||
"browserify>constants-browserify": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-controllers>tar-stream>readable-stream": {
|
||||
"packages": {
|
||||
"browserify>browser-resolve": true,
|
||||
"browserify>buffer": true,
|
||||
"browserify>events": true,
|
||||
"browserify>process": true,
|
||||
"browserify>string_decoder": true,
|
||||
"pumpify>inherits": true,
|
||||
"readable-stream>util-deprecate": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-ui": {
|
||||
"packages": {
|
||||
"@metamask/snaps-ui>@metamask/utils": true,
|
||||
@ -2012,6 +2271,26 @@
|
||||
"@metamask/snaps-utils>@metamask/utils": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-utils>@metamask/snaps-registry": {
|
||||
"packages": {
|
||||
"@metamask/key-tree>@noble/secp256k1": true,
|
||||
"@metamask/snaps-utils>@metamask/snaps-registry>@metamask/utils": true,
|
||||
"superstruct": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-utils>@metamask/snaps-registry>@metamask/utils": {
|
||||
"globals": {
|
||||
"TextDecoder": true,
|
||||
"TextEncoder": true
|
||||
},
|
||||
"packages": {
|
||||
"@metamask/key-tree>@noble/hashes": true,
|
||||
"browserify>buffer": true,
|
||||
"nock>debug": true,
|
||||
"semver": true,
|
||||
"superstruct": true
|
||||
}
|
||||
},
|
||||
"@metamask/snaps-utils>@metamask/utils": {
|
||||
"globals": {
|
||||
"TextDecoder": true,
|
||||
@ -3998,6 +4277,24 @@
|
||||
"Intl": true
|
||||
}
|
||||
},
|
||||
"madge>ora>bl": {
|
||||
"packages": {
|
||||
"browserify>buffer": true,
|
||||
"madge>ora>bl>readable-stream": true,
|
||||
"pumpify>inherits": true
|
||||
}
|
||||
},
|
||||
"madge>ora>bl>readable-stream": {
|
||||
"packages": {
|
||||
"browserify>browser-resolve": true,
|
||||
"browserify>buffer": true,
|
||||
"browserify>events": true,
|
||||
"browserify>process": true,
|
||||
"browserify>string_decoder": true,
|
||||
"pumpify>inherits": true,
|
||||
"readable-stream>util-deprecate": true
|
||||
}
|
||||
},
|
||||
"mocha>serialize-javascript>randombytes": {
|
||||
"globals": {
|
||||
"crypto": true,
|
||||
@ -4262,6 +4559,115 @@
|
||||
"react": true
|
||||
}
|
||||
},
|
||||
"react-markdown": {
|
||||
"globals": {
|
||||
"console.warn": true
|
||||
},
|
||||
"packages": {
|
||||
"prop-types": true,
|
||||
"react": true,
|
||||
"react-markdown>comma-separated-tokens": true,
|
||||
"react-markdown>property-information": true,
|
||||
"react-markdown>react-is": true,
|
||||
"react-markdown>remark-parse": true,
|
||||
"react-markdown>remark-rehype": true,
|
||||
"react-markdown>space-separated-tokens": true,
|
||||
"react-markdown>style-to-object": true,
|
||||
"react-markdown>unified": true,
|
||||
"react-markdown>unist-util-visit": true,
|
||||
"react-markdown>vfile": true
|
||||
}
|
||||
},
|
||||
"react-markdown>property-information": {
|
||||
"packages": {
|
||||
"watchify>xtend": true
|
||||
}
|
||||
},
|
||||
"react-markdown>react-is": {
|
||||
"globals": {
|
||||
"console": true
|
||||
}
|
||||
},
|
||||
"react-markdown>remark-parse": {
|
||||
"packages": {
|
||||
"react-markdown>remark-parse>mdast-util-from-markdown": true
|
||||
}
|
||||
},
|
||||
"react-markdown>remark-parse>mdast-util-from-markdown": {
|
||||
"packages": {
|
||||
"react-markdown>remark-parse>mdast-util-from-markdown>mdast-util-to-string": true,
|
||||
"react-markdown>remark-parse>mdast-util-from-markdown>micromark": true,
|
||||
"react-markdown>remark-parse>mdast-util-from-markdown>unist-util-stringify-position": true,
|
||||
"react-syntax-highlighter>refractor>parse-entities": true
|
||||
}
|
||||
},
|
||||
"react-markdown>remark-parse>mdast-util-from-markdown>micromark": {
|
||||
"packages": {
|
||||
"react-syntax-highlighter>refractor>parse-entities": true
|
||||
}
|
||||
},
|
||||
"react-markdown>remark-rehype": {
|
||||
"packages": {
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast": true
|
||||
}
|
||||
},
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast": {
|
||||
"globals": {
|
||||
"console.warn": true
|
||||
},
|
||||
"packages": {
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast>mdast-util-definitions": true,
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast>mdurl": true,
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast>unist-builder": true,
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast>unist-util-generated": true,
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast>unist-util-position": true,
|
||||
"react-markdown>unist-util-visit": true
|
||||
}
|
||||
},
|
||||
"react-markdown>remark-rehype>mdast-util-to-hast>mdast-util-definitions": {
|
||||
"packages": {
|
||||
"react-markdown>unist-util-visit": true
|
||||
}
|
||||
},
|
||||
"react-markdown>style-to-object": {
|
||||
"packages": {
|
||||
"react-markdown>style-to-object>inline-style-parser": true
|
||||
}
|
||||
},
|
||||
"react-markdown>unified": {
|
||||
"packages": {
|
||||
"mocha>yargs-unparser>is-plain-obj": true,
|
||||
"react-markdown>unified>bail": true,
|
||||
"react-markdown>unified>extend": true,
|
||||
"react-markdown>unified>is-buffer": true,
|
||||
"react-markdown>unified>trough": true,
|
||||
"react-markdown>vfile": true
|
||||
}
|
||||
},
|
||||
"react-markdown>unist-util-visit": {
|
||||
"packages": {
|
||||
"react-markdown>unist-util-visit>unist-util-visit-parents": true
|
||||
}
|
||||
},
|
||||
"react-markdown>unist-util-visit>unist-util-visit-parents": {
|
||||
"packages": {
|
||||
"react-markdown>unist-util-visit>unist-util-is": true
|
||||
}
|
||||
},
|
||||
"react-markdown>vfile": {
|
||||
"packages": {
|
||||
"browserify>path-browserify": true,
|
||||
"browserify>process": true,
|
||||
"react-markdown>vfile>is-buffer": true,
|
||||
"react-markdown>vfile>vfile-message": true,
|
||||
"vinyl>replace-ext": true
|
||||
}
|
||||
},
|
||||
"react-markdown>vfile>vfile-message": {
|
||||
"packages": {
|
||||
"react-markdown>vfile>unist-util-stringify-position": true
|
||||
}
|
||||
},
|
||||
"react-popper": {
|
||||
"globals": {
|
||||
"document": true
|
||||
@ -4416,6 +4822,11 @@
|
||||
"react": true
|
||||
}
|
||||
},
|
||||
"react-syntax-highlighter>refractor>parse-entities": {
|
||||
"globals": {
|
||||
"document.createElement": true
|
||||
}
|
||||
},
|
||||
"react-tippy": {
|
||||
"globals": {
|
||||
"Element": true,
|
||||
@ -4579,12 +4990,22 @@
|
||||
"define": true
|
||||
}
|
||||
},
|
||||
"terser>source-map-support>buffer-from": {
|
||||
"packages": {
|
||||
"browserify>buffer": true
|
||||
}
|
||||
},
|
||||
"uuid": {
|
||||
"globals": {
|
||||
"crypto": true,
|
||||
"msCrypto": true
|
||||
}
|
||||
},
|
||||
"vinyl>replace-ext": {
|
||||
"packages": {
|
||||
"browserify>path-browserify": true
|
||||
}
|
||||
},
|
||||
"web3": {
|
||||
"globals": {
|
||||
"XMLHttpRequest": true
|
||||
|
@ -261,18 +261,18 @@
|
||||
"@metamask/ppom-validator": "^0.2.0",
|
||||
"@metamask/providers": "^11.1.0",
|
||||
"@metamask/rate-limit-controller": "^3.0.0",
|
||||
"@metamask/rpc-methods": "^1.0.0",
|
||||
"@metamask/rpc-methods": "^1.0.1",
|
||||
"@metamask/rpc-methods-flask": "npm:@metamask/rpc-methods@0.37.2-flask.1",
|
||||
"@metamask/safe-event-emitter": "^2.0.0",
|
||||
"@metamask/scure-bip39": "^2.0.3",
|
||||
"@metamask/signature-controller": "^5.3.0",
|
||||
"@metamask/slip44": "^3.0.0",
|
||||
"@metamask/smart-transactions-controller": "^4.0.0",
|
||||
"@metamask/snaps-controllers": "^1.0.0",
|
||||
"@metamask/snaps-controllers": "^1.0.1",
|
||||
"@metamask/snaps-controllers-flask": "npm:@metamask/snaps-controllers@0.38.0-flask.1",
|
||||
"@metamask/snaps-ui": "^1.0.0",
|
||||
"@metamask/snaps-ui": "^1.0.1",
|
||||
"@metamask/snaps-ui-flask": "npm:@metamask/snaps-ui@0.37.3-flask.1",
|
||||
"@metamask/snaps-utils": "^1.0.0",
|
||||
"@metamask/snaps-utils": "^1.0.1",
|
||||
"@metamask/snaps-utils-flask": "npm:@metamask/snaps-utils@0.38.0-flask.1",
|
||||
"@metamask/subject-metadata-controller": "^2.0.0",
|
||||
"@metamask/utils": "^5.0.0",
|
||||
|
@ -4,6 +4,7 @@ const yargs = require('yargs/yargs');
|
||||
const { hideBin } = require('yargs/helpers');
|
||||
const { runInShell } = require('../../development/lib/run-command');
|
||||
const { exitWithError } = require('../../development/lib/exit-with-error');
|
||||
const { loadBuildTypesConfig } = require('../../development/lib/build-type');
|
||||
|
||||
const getTestPathsForTestDir = async (testDir) => {
|
||||
const testFilenames = await fs.readdir(testDir, { withFileTypes: true });
|
||||
@ -64,6 +65,11 @@ async function main() {
|
||||
description: `run json-rpc specific e2e tests`,
|
||||
type: 'boolean',
|
||||
})
|
||||
.option('build-type', {
|
||||
description: `Sets the build-type to test for. This may filter out tests.`,
|
||||
type: 'string',
|
||||
choices: Object.keys(loadBuildTypesConfig().buildTypes),
|
||||
})
|
||||
.option('retries', {
|
||||
description:
|
||||
'Set how many times the test should be retried upon failure.',
|
||||
@ -73,13 +79,25 @@ async function main() {
|
||||
.strict()
|
||||
.help('help');
|
||||
|
||||
const { browser, debug, retries, snaps, mv3, rpc } = argv;
|
||||
const { browser, debug, retries, snaps, mv3, rpc, buildType } = argv;
|
||||
|
||||
let testPaths;
|
||||
|
||||
if (snaps) {
|
||||
const testDir = path.join(__dirname, 'snaps');
|
||||
testPaths = await getTestPathsForTestDir(testDir);
|
||||
|
||||
if (buildType && buildType !== 'flask') {
|
||||
// These tests should only be ran on Flask for now
|
||||
const filteredTests = [
|
||||
'test-snap-manageAccount.spec.js',
|
||||
'test-snap-rpc.spec.js',
|
||||
'test-snap-lifecycle.spec.js',
|
||||
];
|
||||
testPaths = testPaths.filter((p) =>
|
||||
filteredTests.every((filteredTest) => !p.endsWith(filteredTest)),
|
||||
);
|
||||
}
|
||||
} else if (rpc) {
|
||||
const testDir = path.join(__dirname, 'json-rpc');
|
||||
testPaths = await getTestPathsForTestDir(testDir);
|
||||
|
@ -142,6 +142,13 @@
|
||||
"allNftContracts": "object",
|
||||
"allNfts": "object",
|
||||
"ignoredNfts": "object",
|
||||
"snapErrors": "object",
|
||||
"snaps": "object",
|
||||
"snapStates": "object",
|
||||
"jobs": "object",
|
||||
"database": "object",
|
||||
"lastUpdated": "object",
|
||||
"notifications": "object",
|
||||
"accounts": "object",
|
||||
"currentNetworkTxList": "object",
|
||||
"unapprovedDecryptMsgs": "object",
|
||||
|
64
yarn.lock
64
yarn.lock
@ -4707,22 +4707,22 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@metamask/rpc-methods@npm:^1.0.0":
|
||||
version: 1.0.0
|
||||
resolution: "@metamask/rpc-methods@npm:1.0.0"
|
||||
"@metamask/rpc-methods@npm:^1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "@metamask/rpc-methods@npm:1.0.1"
|
||||
dependencies:
|
||||
"@metamask/browser-passworder": "npm:^4.0.2"
|
||||
"@metamask/key-tree": "npm:^7.1.1"
|
||||
"@metamask/permission-controller": "npm:^4.0.0"
|
||||
"@metamask/snaps-ui": "npm:^1.0.0"
|
||||
"@metamask/snaps-utils": "npm:^1.0.0"
|
||||
"@metamask/snaps-ui": "npm:^1.0.1"
|
||||
"@metamask/snaps-utils": "npm:^1.0.1"
|
||||
"@metamask/types": "npm:^1.1.0"
|
||||
"@metamask/utils": "npm:^6.0.1"
|
||||
"@noble/hashes": "npm:^1.1.3"
|
||||
eth-rpc-errors: "npm:^4.0.2"
|
||||
nanoid: "npm:^3.1.31"
|
||||
superstruct: "npm:^1.0.3"
|
||||
checksum: 7e5f2900f9a54bcc112d9861eeb461de5a7803fdaa4e1bfee1c1c9f68a659dc42f56a7dbbc4f8147f66927c7192d1b5314cc32ca5d8985b969694582127b8fa8
|
||||
checksum: 2e88d739780361901820ae6ba683b14898dafaee8bb05b169f6074265a3c2aa60b9f66fdbc5003e65ed656bce3a2090c6f6d1ea800c1ac7f035dfa21adcccddd
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@ -4872,19 +4872,19 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@metamask/snaps-controllers@npm:^1.0.0":
|
||||
version: 1.0.0
|
||||
resolution: "@metamask/snaps-controllers@npm:1.0.0"
|
||||
"@metamask/snaps-controllers@npm:^1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "@metamask/snaps-controllers@npm:1.0.1"
|
||||
dependencies:
|
||||
"@metamask/approval-controller": "npm:^3.0.0"
|
||||
"@metamask/base-controller": "npm:^3.0.0"
|
||||
"@metamask/object-multiplex": "npm:^1.2.0"
|
||||
"@metamask/permission-controller": "npm:^4.0.0"
|
||||
"@metamask/post-message-stream": "npm:^6.1.2"
|
||||
"@metamask/rpc-methods": "npm:^1.0.0"
|
||||
"@metamask/snaps-execution-environments": "npm:^1.0.0"
|
||||
"@metamask/rpc-methods": "npm:^1.0.1"
|
||||
"@metamask/snaps-execution-environments": "npm:^1.0.1"
|
||||
"@metamask/snaps-registry": "npm:^1.2.1"
|
||||
"@metamask/snaps-utils": "npm:^1.0.0"
|
||||
"@metamask/snaps-utils": "npm:^1.0.1"
|
||||
"@metamask/utils": "npm:^6.0.1"
|
||||
"@xstate/fsm": "npm:^2.0.0"
|
||||
concat-stream: "npm:^2.0.0"
|
||||
@ -4898,7 +4898,7 @@ __metadata:
|
||||
pump: "npm:^3.0.0"
|
||||
readable-web-to-node-stream: "npm:^3.0.2"
|
||||
tar-stream: "npm:^2.2.0"
|
||||
checksum: f9ab5a5f593d5d0e971e682d3b32758d30e4bb444ba48f2f66dcf662305ed5c38394fadab32c625d9d171025736637c15765e443d01ef6be247ab75875e0e2e5
|
||||
checksum: 68b779618e97e5b55c4899c08a48230a41bc64b5bc86330f75167396afe65e0f5eefc8db0a70a08866d713144fe02457dd2705e97d600f403c785ebcb5e12ef8
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@ -4944,15 +4944,15 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@metamask/snaps-execution-environments@npm:^1.0.0":
|
||||
version: 1.0.0
|
||||
resolution: "@metamask/snaps-execution-environments@npm:1.0.0"
|
||||
"@metamask/snaps-execution-environments@npm:^1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "@metamask/snaps-execution-environments@npm:1.0.1"
|
||||
dependencies:
|
||||
"@metamask/object-multiplex": "npm:^1.2.0"
|
||||
"@metamask/post-message-stream": "npm:^6.1.1"
|
||||
"@metamask/providers": "npm:^10.2.0"
|
||||
"@metamask/rpc-methods": "npm:^1.0.0"
|
||||
"@metamask/snaps-utils": "npm:^1.0.0"
|
||||
"@metamask/rpc-methods": "npm:^1.0.1"
|
||||
"@metamask/snaps-utils": "npm:^1.0.1"
|
||||
"@metamask/utils": "npm:^6.0.1"
|
||||
eth-rpc-errors: "npm:^4.0.3"
|
||||
json-rpc-engine: "npm:^6.1.0"
|
||||
@ -4960,7 +4960,7 @@ __metadata:
|
||||
ses: "npm:^0.18.1"
|
||||
stream-browserify: "npm:^3.0.0"
|
||||
superstruct: "npm:^1.0.3"
|
||||
checksum: 744af06aab2952da69efa6922eb886a6cdbbec0368b35d3d253ecedcc940001e08b2496aa87acfbfe88d7e38955c8e807e942a4c86fc6c01ed86ce44f2106180
|
||||
checksum: 69a7d94c3d9b4838f72330bb7956c1bf27eb856d481d66669ac2461294e1e8491108385b510a83ff02edb08eca3236889ef74482a3eaefc6e8bc540b3f7880c0
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@ -5005,13 +5005,13 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@metamask/snaps-ui@npm:^1.0.0":
|
||||
version: 1.0.0
|
||||
resolution: "@metamask/snaps-ui@npm:1.0.0"
|
||||
"@metamask/snaps-ui@npm:^1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "@metamask/snaps-ui@npm:1.0.1"
|
||||
dependencies:
|
||||
"@metamask/utils": "npm:^6.0.1"
|
||||
superstruct: "npm:^1.0.3"
|
||||
checksum: 805d23c43eb9a5d7ed7d332c9f98187b755142aeb37129d29a5153d2c9bd995beb5508a4d7f26b9d958d403768decded133d8b0c9935d3ac691f6e26fa81c285
|
||||
checksum: c3eb4808ffeb94b4d7a7f52b5827ee866ebf488c2abab8599f1f002f85eb5b39d1e2ca639258f75e8b9cc850f969bddbdb2de5c491a8d4d7f3912de8ad26ec27
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@ -5104,9 +5104,9 @@ __metadata:
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@metamask/snaps-utils@npm:^1.0.0":
|
||||
version: 1.0.0
|
||||
resolution: "@metamask/snaps-utils@npm:1.0.0"
|
||||
"@metamask/snaps-utils@npm:^1.0.1":
|
||||
version: 1.0.1
|
||||
resolution: "@metamask/snaps-utils@npm:1.0.1"
|
||||
dependencies:
|
||||
"@babel/core": "npm:^7.18.6"
|
||||
"@babel/types": "npm:^7.18.7"
|
||||
@ -5115,7 +5115,7 @@ __metadata:
|
||||
"@metamask/permission-controller": "npm:^4.0.0"
|
||||
"@metamask/providers": "npm:^10.2.1"
|
||||
"@metamask/snaps-registry": "npm:^1.2.1"
|
||||
"@metamask/snaps-ui": "npm:^1.0.0"
|
||||
"@metamask/snaps-ui": "npm:^1.0.1"
|
||||
"@metamask/utils": "npm:^6.0.1"
|
||||
"@noble/hashes": "npm:^1.1.3"
|
||||
"@scure/base": "npm:^1.1.1"
|
||||
@ -5128,7 +5128,7 @@ __metadata:
|
||||
ses: "npm:^0.18.7"
|
||||
superstruct: "npm:^1.0.3"
|
||||
validate-npm-package-name: "npm:^5.0.0"
|
||||
checksum: daf2ff95c7fbd3c68ef47b3816aba9fbbe7363adc780500fe03b3b0b0ba23ca382e16feeb6deb909d458e08c035214e5819a48d8f7456499934299224f980b8f
|
||||
checksum: 45ef36809b41c71b79bd49c19450efdb999c5b738ce0989b6880ae117b172d44519967334ade650ae6239c5068e71c019e096f6ac6155aa23bb26d98fe5294af
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
@ -24287,18 +24287,18 @@ __metadata:
|
||||
"@metamask/ppom-validator": "npm:^0.2.0"
|
||||
"@metamask/providers": "npm:^11.1.0"
|
||||
"@metamask/rate-limit-controller": "npm:^3.0.0"
|
||||
"@metamask/rpc-methods": "npm:^1.0.0"
|
||||
"@metamask/rpc-methods": "npm:^1.0.1"
|
||||
"@metamask/rpc-methods-flask": "npm:@metamask/rpc-methods@0.37.2-flask.1"
|
||||
"@metamask/safe-event-emitter": "npm:^2.0.0"
|
||||
"@metamask/scure-bip39": "npm:^2.0.3"
|
||||
"@metamask/signature-controller": "npm:^5.3.0"
|
||||
"@metamask/slip44": "npm:^3.0.0"
|
||||
"@metamask/smart-transactions-controller": "npm:^4.0.0"
|
||||
"@metamask/snaps-controllers": "npm:^1.0.0"
|
||||
"@metamask/snaps-controllers": "npm:^1.0.1"
|
||||
"@metamask/snaps-controllers-flask": "npm:@metamask/snaps-controllers@0.38.0-flask.1"
|
||||
"@metamask/snaps-ui": "npm:^1.0.0"
|
||||
"@metamask/snaps-ui": "npm:^1.0.1"
|
||||
"@metamask/snaps-ui-flask": "npm:@metamask/snaps-ui@0.37.3-flask.1"
|
||||
"@metamask/snaps-utils": "npm:^1.0.0"
|
||||
"@metamask/snaps-utils": "npm:^1.0.1"
|
||||
"@metamask/snaps-utils-flask": "npm:@metamask/snaps-utils@0.38.0-flask.1"
|
||||
"@metamask/subject-metadata-controller": "npm:^2.0.0"
|
||||
"@metamask/test-dapp": "npm:^7.0.1"
|
||||
|
Loading…
Reference in New Issue
Block a user