diff --git a/.github/workflows/check-build.yml b/.github/workflows/check-build.yml new file mode 100644 index 0000000..f41aa4c --- /dev/null +++ b/.github/workflows/check-build.yml @@ -0,0 +1,29 @@ +name: Test and Build VSCode + +on: + push: + branches: + - main + +jobs: + build: + strategy: + matrix: + os: [macos-latest, ubuntu-latest, windows-latest] + runs-on: ${{ matrix.os }} + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install Node.js + uses: actions/setup-node@v2 + with: + node-version: 18.x + + - run: npm install + + - run: xvfb-run -a npm test + if: runner.os == 'Linux' + + - run: npm test + if: runner.os != 'Linux' diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 9850d59..1087935 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -2,7 +2,7 @@ name: Publish Extension on: workflow_run: - workflows: ["Test VsCode Extension"] + workflows: ["Test and Build VSCode"] types: - completed diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ff64450..b842993 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -2,7 +2,7 @@ name: Release on: workflow_run: - workflows: ["Test VsCode Extension"] + workflows: ["Test and Build VSCode"] types: - completed diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5bb67db..1993de6 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,9 +1,10 @@ name: Test VsCode Extension on: - push: + pull_request: branches: - - master + - main + jobs: build: