Skip to content

Testing/test runner #18

Testing/test runner

Testing/test runner #18

Workflow file for this run

name: main
on:
push:
branches: [main]
pull_request:
types: [opened, synchronize]
concurrency:
group: github.head_ref
cancel-in-progress: true
jobs:
lint:
runs-on: ubuntu-latest
name: lint
steps:
- uses: actions/checkout@v3
- uses: JohnnyMorganz/stylua-action@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
version: latest
args: --check .
tests:
needs:
- lint
#- documentation
runs-on: ubuntu-latest
timeout-minutes: 2
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
neovim_version: ["v0.10.0", "nightly"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: "9.0.x"
- name: Install C/C++ Compiler
uses: rlalik/setup-cpp-compiler@master
with:
compiler: clang-latest
- name: Install tree-sitter CLI
uses: baptiste0928/cargo-install@v3
with:
crate: tree-sitter-cli
- name: Run tests
id: test
uses: nvim-neorocks/nvim-busted-action@v1
with:
nvim_version: ${{ matrix.neovim_version }}
- name: Save neotest log
if: always() && steps.test.outcome == 'failure'
uses: actions/upload-artifact@v4
with:
name: neotest-log-${{ matrix.neovim_version }}-${{ matrix.os }}
path: ~/.local/state/nvim/neotest.log
release:
name: release
if: ${{ github.ref == 'refs/heads/main' }}
needs:
- tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: google-github-actions/release-please-action@v3
id: release
with:
release-type: simple
package-name: neotest-dotnet
- name: tag stable versions
if: ${{ steps.release.outputs.release_created }}
run: |
git config user.name github-actions[bot]
git config user.email github-actions[bot]@users.noreply.github.com
git remote add gh-token "https://${{ secrets.GITHUB_TOKEN }}@github.com/google-github-actions/release-please-action.git"
git tag -d stable || true
git push origin :stable || true
git tag -a stable -m "Last Stable Release"
git push origin stable