From f4d6a1df19f8aade086feb7a226db28839656b1c Mon Sep 17 00:00:00 2001 From: Vincent Weevers Date: Tue, 20 Apr 2021 21:30:42 +0200 Subject: [PATCH] Add code coverage to browser tests --- .github/workflows/sauce.yml | 6 ++++++ package.json | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sauce.yml b/.github/workflows/sauce.yml index c70a2d3f..57729e43 100644 --- a/.github/workflows/sauce.yml +++ b/.github/workflows/sauce.yml @@ -23,3 +23,9 @@ jobs: env: SAUCE_USERNAME: ${{ secrets.SAUCE_USERNAME }} SAUCE_ACCESS_KEY: ${{ secrets.SAUCE_ACCESS_KEY }} + - name: Coverage + run: npm run coverage + - name: Codecov + uses: codecov/codecov-action@v1 + with: + file: coverage/lcov.info diff --git a/package.json b/package.json index f436f071..c0e02e31 100644 --- a/package.json +++ b/package.json @@ -10,7 +10,7 @@ "scripts": { "test": "standard && hallmark && (nyc -s node test/self.js | faucet) && nyc report", "coverage": "nyc report -r lcovonly", - "test-browsers": "airtap --verbose test/self.js > airtap.log", + "test-browsers": "airtap --coverage --verbose test/self.js", "test-browsers-local": "airtap -p local test/self.js", "hallmark": "hallmark --fix", "dependency-check": "dependency-check --no-dev -i queue-microtask .",