Skip to content

Commit

Permalink
Add MacOs test runner
Browse files Browse the repository at this point in the history
  • Loading branch information
Spacetown committed Feb 29, 2024
1 parent af98e42 commit 803a6d3
Showing 1 changed file with 17 additions and 7 deletions.
24 changes: 17 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,22 @@ jobs:
gcc: gcc-8
python-version: '3.11'

# Test minimum and maximum Python version on Windows.
- os: macos-12
gcc: gcc
python-version: '3.8'
- os: macos-12
gcc: gcc
python-version: '3.11'

steps:
- uses: actions/checkout@v4
- name: Setup environment
run: |
# Enable coverage for specific target configurations
case "${{ matrix.os }}/${{ matrix.gcc }}/${{ matrix.python-version }}" in
windows-2019/gcc-8/3.8) USE_COVERAGE=true ;;
macos-12/gcc-11/3.9) USE_COVERAGE=true ;;
ubuntu-22.04/gcc-11/3.11) USE_COVERAGE=true ;;
*) USE_COVERAGE=false ;;
esac
Expand All @@ -135,20 +144,21 @@ jobs:
if: ${{ startsWith(matrix.os,'windows-') }}
run: |
choco install ninja
- name: Install build commands and GCC (Linux)
- name: Install ninja and libxml2 (MacOs)
if: ${{ startsWith(matrix.os,'macos-') }}
run: |
brew update
brew install ninja
brew install libxml2
- name: Install build commands, GCC and libxml2 (Linux)
if: ${{ startsWith(matrix.os,'ubuntu-') }}
run: |
sudo apt update
sudo apt-get install -y \
make \
ninja-build \
${{ matrix.gcc }} \
$(echo ${{ matrix.gcc }} | sed -e 's/gcc/g\+\+/')
sudo apt-get clean
- name: Install libxml2
if: ${{ startsWith(matrix.os,'ubuntu-') }}
run: |
sudo apt-get install -y \
$(echo ${{ matrix.gcc }} | sed -e 's/gcc/g\+\+/') \
libxml2-utils
sudo apt-get clean
- name: Set up Python ${{ matrix.python-version }}
Expand Down

0 comments on commit 803a6d3

Please sign in to comment.