From dde44120d87f29db06379df2e4bbea5a3ec40c69 Mon Sep 17 00:00:00 2001 From: unadlib Date: Sun, 29 Sep 2024 05:05:55 +0800 Subject: [PATCH] ci(github): update --- .github/workflows/pull-request.yml | 28 ++++++++++++++++++++++++++++ .github/workflows/tests.yml | 2 +- 2 files changed, 29 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/pull-request.yml diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml new file mode 100644 index 0000000..b22f324 --- /dev/null +++ b/.github/workflows/pull-request.yml @@ -0,0 +1,28 @@ +on: ["pull_request"] + +name: Test Coveralls + +jobs: + + build: + name: Build + runs-on: ubuntu-latest + steps: + + - uses: actions/checkout@v1 + + - name: Use Node.js 18.x + uses: actions/setup-node@v1 + with: + node-version: 18.x + + - name: yarn install, yarn test:coverage + run: | + yarn install + echo repo_token: ${{ secrets.COVERALLS_REPO_TOKEN }} > .coveralls.yml + yarn test:coverage + + - name: Coveralls + uses: romeovs/lcov-reporter-action@v0.4.0 + with: + lcov-file: ./coverage/lcov.info diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e3f2e95..caca75a 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -1,4 +1,4 @@ -on: ["push", "pull_request"] +on: ["push"] name: Test Coveralls