diff --git a/.gitignore b/.gitignore index c2560c19e..85086780e 100644 --- a/.gitignore +++ b/.gitignore @@ -18,3 +18,4 @@ packages/_generated/src !.yarn/releases !.yarn/sdks !.yarn/versions +coverage diff --git a/Makefile b/Makefile index d1e57ed22..caf79aa40 100644 --- a/Makefile +++ b/Makefile @@ -53,6 +53,9 @@ playground-test: playground-test-watch: yarn workspace playground run test:watch +playground-test-coverage: + yarn workspace playground run test:coverage + playground-bundlesize: yarn workspace playground run bundlesize @@ -69,6 +72,9 @@ components-test: components-test-watch: yarn workspace @paritytech/components run test:watch +components-test-coverage: + yarn workspace @paritytech/components run test:coverage + ################################################################################ # ENTRYPOINT: crate-extractor ################################################################################ diff --git a/packages/components/package.json b/packages/components/package.json index 8a6403cbd..aa7f428be 100644 --- a/packages/components/package.json +++ b/packages/components/package.json @@ -7,7 +7,8 @@ "clean": "rimraf dist pkg node_modules", "test": "jest --update-snapshot", "test:watch": "jest --update-snapshot --watch", - "test:clear": "jest --clearCache" + "test:clear": "jest --clearCache", + "test:coverage": "jest --update-snapshot --collectCoverage" }, "author": "", "license": "ISC", diff --git a/packages/playground/package.json b/packages/playground/package.json index 7a1a1bd2c..f5507669d 100644 --- a/packages/playground/package.json +++ b/packages/playground/package.json @@ -16,6 +16,7 @@ "test": "jest --update-snapshot", "test:watch": "jest --update-snapshot --watch", "test:clear": "jest --clearCache", + "test:coverage": "jest --update-snapshot --collectCoverage", "bundlesize": "yarn bundlesize:generate && webpack-bundle-analyzer --port 8081 bundle-size-stats.json dist", "bundlesize:generate": "yarn build && yarn webpack --stats --json=bundle-size-stats.json" },