-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #252 from VirtualPlanetaryLaboratory/os-tests
Added workflows to test Linux and Mac builds. Windows users will have to use the Windows Subsystem for Linux: https://learn.microsoft.com/en-us/windows/wsl/install. The code is now checked on Ubuntu 20.04 and 22.04, MacOS 11, 12 and 13.
- Loading branch information
Showing
9 changed files
with
145 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
name: tests-macos | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
workflow_dispatch: | ||
|
||
jobs: | ||
tests: | ||
name: '${{ matrix.os }}:python-${{ matrix.python-version }}' | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [macos-11, macos-12, macos-13] | ||
python-version: ['3.6', '3.7', '3.8', '3.9', '3.10', '3.11', '3.12'] | ||
fail-fast: false | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Set up Python | ||
id: setup_python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install dependencies | ||
if: steps.setup_python.outcome == 'success' | ||
run: | | ||
python -m pip install -U pip | ||
python -m pip install -e . | ||
python -m pip install pytest pytest-cov | ||
- name: Run tests | ||
if: steps.setup_python.outcome == 'success' | ||
run: make test | ||
|
||
- name: Check test ouptut created | ||
id: check_test_file | ||
uses: andstor/file-existence-action@v2 | ||
with: | ||
files: "/home/runner/work/vplanet/vplanet/junit/test-results.xml" | ||
fail: true | ||
|
||
- name: Get unique id | ||
uses: Tiryoh/gha-jobid-action@v1 | ||
id: jobs | ||
|
||
- name: Publish unit test results | ||
uses: EnricoMi/publish-unit-test-result-action/composite@v2 | ||
if: always() | ||
with: | ||
files: junit/test-*.xml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.