diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..ddae6ff --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,40 @@ +name: CI + +on: + push: + branches: ["*"] + paths: + - grammar.js + - src/** + - test/** + - bindings/** + - binding.gyp + pull_request: + paths: + - grammar.js + - src/** + - test/** + - bindings/** + - binding.gyp + +concurrency: + group: ${{github.workflow}}-${{github.ref}} + cancel-in-progress: true + +jobs: + test: + name: Test parser + runs-on: ${{matrix.os}} + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, windows-latest, macos-14] + steps: + - name: Checkout repository + uses: actions/checkout@v4 + - name: Set up tree-sitter + uses: tree-sitter/setup-action/cli@v1 + # Ensure the generated parser is up to date + - run: tree-sitter generate + - name: Run tests + uses: tree-sitter/parser-test-action@v2