Skip to content

Commit

Permalink
Fix macOS tests (#2095)
Browse files Browse the repository at this point in the history
  • Loading branch information
m3nu authored Oct 18, 2024
1 parent 85c30ca commit cf4370a
Show file tree
Hide file tree
Showing 4 changed files with 225 additions and 212 deletions.
24 changes: 12 additions & 12 deletions .github/scripts/generate-matrix.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,28 +3,28 @@ branch_name="$2"

if [[ "$event_name" == "workflow_dispatch" ]] || [[ "$branch_name" == "master" ]]; then
echo '{
"python-version": ["3.8", "3.9", "3.10", "3.11"],
"os": ["ubuntu-22.04", "macos-12"],
"borg-version": ["1.2.4"]
"python-version": ["3.9", "3.10", "3.11"],
"os": ["ubuntu-22.04", "macos-14"],
"borg-version": ["1.4.0"]
}' | jq -c . > matrix-unit.json

echo '{
"python-version": ["3.8", "3.9", "3.10", "3.11"],
"os": ["ubuntu-22.04", "macos-12"],
"borg-version": ["1.1.18", "1.2.2", "1.2.4", "2.0.0b5"],
"exclude": [{"borg-version": "2.0.0b5", "python-version": "3.8"}]
"python-version": ["3.9", "3.10", "3.11"],
"os": ["ubuntu-22.04", "macos-14"],
"borg-version": ["1.1.18", "1.2.8", "1.4.0", "2.0.0b12"],
"exclude": [{"borg-version": "2.0.0b12", "python-version": "3.8"}]
}' | jq -c . > matrix-integration.json

elif [[ "$event_name" == "push" ]] || [[ "$event_name" == "pull_request" ]]; then
echo '{
"python-version": ["3.8", "3.9", "3.10", "3.11"],
"os": ["ubuntu-22.04", "macos-12"],
"borg-version": ["1.2.4"]
"python-version": ["3.9", "3.11"],
"os": ["ubuntu-22.04", "macos-14"],
"borg-version": ["1.2.8"]
}' | jq -c . > matrix-unit.json

echo '{
"python-version": ["3.10"],
"python-version": ["3.11"],
"os": ["ubuntu-22.04"],
"borg-version": ["1.2.4"]
"borg-version": ["1.2.8"]
}' | jq -c . > matrix-integration.json
fi
6 changes: 3 additions & 3 deletions .github/workflows/build-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ jobs:
run: |
brew install --cask sparkle
brew install create-dmg
pip3 install --upgrade pip
pip3 install -r dev.txt
pip3 install --break-system-packages --upgrade pip
pip3 install --break-system-packages -r dev.txt
working-directory: requirements.d
- name: Install Vorta
run: |
pip3 install .
pip3 install --break-system-packages .
- name: Package with PyInstaller
run: |
pyinstaller --clean --noconfirm package/vorta.spec
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ jobs:

test-unit:
needs: prepare-matrix
timeout-minutes: 20
timeout-minutes: 60 # macos tests are very slow
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
Expand Down Expand Up @@ -137,10 +137,11 @@ jobs:
run: echo $PKG_CONFIG_PATH && make test-integration

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
env:
OS: ${{ runner.os }}
python: ${{ matrix.python-version }}
with:
token: ${{ secrets.CODECOV_TOKEN }}
env_vars: OS, python
version: v0.7.3 # workaround on Intel macs (GH Actions)
Loading

0 comments on commit cf4370a

Please sign in to comment.