mirror of
https://github.com/tiennm99/serena.git
synced 2026-07-14 11:08:47 +00:00
GH: run tests on all OS
This commit is contained in:
@@ -1,13 +1,15 @@
|
||||
name: Tests on Ubuntu
|
||||
name: Tests on CI
|
||||
|
||||
on: [pull_request]
|
||||
|
||||
jobs:
|
||||
cpu:
|
||||
runs-on: ubuntu-latest
|
||||
name: Tests on ${{ matrix.os }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
if: "!contains(github.event.head_commit.message, 'ci skip')"
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||
python-version: ["3.11"]
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
@@ -20,17 +22,26 @@ jobs:
|
||||
# GITHUB_PATH is a special file that GitHub Actions uses to modify PATH
|
||||
# Writing to this file adds the directory to the PATH for subsequent steps
|
||||
- name: Install gopls
|
||||
shell: bash
|
||||
run: |
|
||||
go install golang.org/x/tools/gopls@latest
|
||||
echo "$HOME/go/bin" >> $GITHUB_PATH
|
||||
|
||||
if [ "$RUNNER_OS" = "Windows" ]; then
|
||||
echo "$HOME/go/bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
|
||||
else
|
||||
echo "$HOME/go/bin" >> $GITHUB_PATH
|
||||
fi
|
||||
|
||||
- name: Install uv
|
||||
shell: bash
|
||||
run: curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||
- name: Create virtual environment
|
||||
shell: bash
|
||||
run: uv venv
|
||||
- name: Install dependencies
|
||||
shell: bash
|
||||
run: uv pip install -e ".[dev]"
|
||||
- name: Test with pytest
|
||||
shell: bash
|
||||
run: uv run poe test
|
||||
- name: Upload coverage to Codecov
|
||||
uses: codecov/codecov-action@v1
|
||||
|
||||
Reference in New Issue
Block a user