From 708c01308258a2d5829314754d1f0cbcca40de22 Mon Sep 17 00:00:00 2001 From: Phred Lane Date: Tue, 20 Aug 2019 13:27:23 -0500 Subject: [PATCH 1/7] added github workflow Using UI since CLI doesn't seem to work --- .github/workflows/main.yml | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 000000000..81c94ac17 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,34 @@ +name: Node CI + +on: [push] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [6.x, 8.x, 10.x, 12.x] + + steps: + - uses: actions/checkout@v1 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v1 + with: + node-version: ${{ matrix.node-version }} + - name: npm ci + run: npm ci + + - name: Pre-Test + run: | + npm run lint + + npm run test-headless -- --chrome $(which google-chrome-stable) --allow-chrome-as-root + npm run test-webworker -- --chrome $(which google-chrome-stable) --allow-chrome-as-root + npm run test-esm-bundle + if: matrix.node-version == '10.x' + + - name: npm test + run: npm run test-node + From 506053cff66c7be99618c04261cb86578ec12a42 Mon Sep 17 00:00:00 2001 From: Phred Lane Date: Tue, 20 Aug 2019 13:33:39 -0500 Subject: [PATCH 2/7] switch to npm install --- .github/workflows/main.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 81c94ac17..7929d3d1a 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -17,8 +17,8 @@ jobs: uses: actions/setup-node@v1 with: node-version: ${{ matrix.node-version }} - - name: npm ci - run: npm ci + - name: npm install + run: npm install - name: Pre-Test run: | From 8723ed07710ea8e2d6856f64dd8444f0f6168178 Mon Sep 17 00:00:00 2001 From: Phred Date: Tue, 20 Aug 2019 16:35:52 -0500 Subject: [PATCH 3/7] removed node 6 trying 'npm ci' again --- .github/workflows/main.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 7929d3d1a..c1e141131 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -9,7 +9,7 @@ jobs: strategy: matrix: - node-version: [6.x, 8.x, 10.x, 12.x] + node-version: [8.x, 10.x, 12.x] steps: - uses: actions/checkout@v1 @@ -17,8 +17,8 @@ jobs: uses: actions/setup-node@v1 with: node-version: ${{ matrix.node-version }} - - name: npm install - run: npm install + - name: npm ci + run: npm ci - name: Pre-Test run: | From 88cf7a9cab8dc510d57a2e434c2d41376addad1f Mon Sep 17 00:00:00 2001 From: Phred Date: Mon, 26 Aug 2019 19:32:20 -0500 Subject: [PATCH 4/7] added code coverage --- .github/workflows/main.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index c1e141131..83cb02017 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -3,13 +3,12 @@ name: Node CI on: [push] jobs: - build: - + test: runs-on: ubuntu-latest strategy: matrix: - node-version: [8.x, 10.x, 12.x] + node-version: [8, 10, 12] steps: - uses: actions/checkout@v1 @@ -17,9 +16,7 @@ jobs: uses: actions/setup-node@v1 with: node-version: ${{ matrix.node-version }} - - name: npm ci - run: npm ci - + - run: npm ci - name: Pre-Test run: | npm run lint @@ -27,8 +24,13 @@ jobs: npm run test-headless -- --chrome $(which google-chrome-stable) --allow-chrome-as-root npm run test-webworker -- --chrome $(which google-chrome-stable) --allow-chrome-as-root npm run test-esm-bundle - if: matrix.node-version == '10.x' + if: matrix.node-version == 10 - name: npm test run: npm run test-node + - name: code coverage + run: | + npm run test-coverage -- --chrome $(which google-chrome-stable) --allow-chrome-as-root + cat ./coverage/lcov.info | coveralls lib + if: matrix.node-version == 10 From cf0f402becc76ac6d45a0647d8a820b144c42a09 Mon Sep 17 00:00:00 2001 From: Phred Lane Date: Tue, 27 Aug 2019 00:25:19 -0500 Subject: [PATCH 5/7] added coveralls (via npx) --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 83cb02017..e232c0e41 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -32,5 +32,5 @@ jobs: - name: code coverage run: | npm run test-coverage -- --chrome $(which google-chrome-stable) --allow-chrome-as-root - cat ./coverage/lcov.info | coveralls lib + cat ./coverage/lcov.info | npx coveralls lib if: matrix.node-version == 10 From 8525f4d10ec922bd852b401450e36c989f92bdd6 Mon Sep 17 00:00:00 2001 From: Phred Date: Tue, 27 Aug 2019 06:14:14 -0500 Subject: [PATCH 6/7] trying built-in coveralls support --- .github/workflows/main.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e232c0e41..437a0f58c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -29,8 +29,11 @@ jobs: - name: npm test run: npm run test-node + - name: generate coverage + run: npm run test-coverage -- --chrome $(which google-chrome-stable) --allow-chrome-as-root + if: matrix.node-version == 10 - name: code coverage - run: | - npm run test-coverage -- --chrome $(which google-chrome-stable) --allow-chrome-as-root - cat ./coverage/lcov.info | npx coveralls lib + uses: coverallsapp/github-action@master + with: + github-token: ${{ secrets.github_token }} if: matrix.node-version == 10 From 261c4cd16b81fa7825f93c9d96f951491bc3deaf Mon Sep 17 00:00:00 2001 From: Phred Date: Tue, 27 Aug 2019 06:24:53 -0500 Subject: [PATCH 7/7] renamed step --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 437a0f58c..22fe32fd8 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -32,7 +32,7 @@ jobs: - name: generate coverage run: npm run test-coverage -- --chrome $(which google-chrome-stable) --allow-chrome-as-root if: matrix.node-version == 10 - - name: code coverage + - name: coveralls uses: coverallsapp/github-action@master with: github-token: ${{ secrets.github_token }}