From de9ecb7c300219282252e2b61dd687a12af5d8f5 Mon Sep 17 00:00:00 2001 From: Matthew Shao Date: Sun, 26 Mar 2017 09:36:18 +0800 Subject: [web] Add JS coverage to codecov. --- .travis.yml | 6 ++++-- web/package.json | 4 +++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index e64bf6d4..d411ac0b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -52,8 +52,10 @@ matrix: before_install: - curl -o- -L https://yarnpkg.com/install.sh | bash - export PATH=$HOME/.yarn/bin:$PATH - install: cd web && yarn - script: npm test + install: + - cd web && yarn + - yarn global add codecov + script: npm test && codecov cache: yarn: true directories: diff --git a/web/package.json b/web/package.json index f0b3ae6a..8e4140bf 100644 --- a/web/package.json +++ b/web/package.json @@ -13,7 +13,9 @@ ], "unmockedModulePathPatterns": [ "react" - ] + ], + "coverageDirectory":"./coverage", + "collectCoverage": true }, "dependencies": { "bootstrap": "^3.3.7", -- cgit v1.2.3