diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..9bd4469 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,31 @@ +name: Node.js CI + +on: + push: + branches: ["main"] + pull_request: + branches: ["main"] + + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x, 16.x, 18.x] + + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Setup Node.js environment + uses: actions/setup-node@v4.0.0 + with: + node-version: ${{ matrix.node-version }} + - name: Setup pnpm + uses: pnpm/action-setup@v2.4.0 + with: + version: 8 + - name: Install and run tests + run: pnpm it