From a067d83a63669fcfdff297337cfbe740b036e0f1 Mon Sep 17 00:00:00 2001 From: Iwo Plaza Date: Sun, 7 Jul 2024 18:22:37 +0200 Subject: [PATCH] Running tests in CI --- .github/workflows/coverage.yml | 35 ++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/coverage.yml diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml new file mode 100644 index 0000000..bacc19f --- /dev/null +++ b/.github/workflows/coverage.yml @@ -0,0 +1,35 @@ +name: Tests + +on: + push: + branches: [main] + pull_request: + branches: [main] + +jobs: + # Runs all steps on the VM + test: + runs-on: ${{ matrix.os }} + + strategy: + matrix: + os: [ubuntu-latest, windows-latest, macos-latest] + node-version: [18.x, 20.x, 22.x] + + steps: + - name: Checkout Code Repository + uses: actions/checkout@v2 + + - uses: pnpm/action-setup@v4 + name: Install pnpm + with: + run_install: false + + - name: Use Node.js ${{ matrix.node-version }} on ${{ matrix.os }} + uses: actions/setup-node@v4 + with: + node-version: ${{ matrix.node-version }} + cache: "pnpm" + + - run: pnpm i --frozen-lockfile + - run: pnpm test