Skip to content

Commit

Permalink
CI: Test on x86_64-apple-darwin
Browse files Browse the repository at this point in the history
Since performance testing happens on macOS (for aarch64), it would
be nice to automatically test breakage on macOS although GitHub
actions do not offer any arch64-apple-darwin test runners at the
moment.
  • Loading branch information
thedataking committed Jul 11, 2023
1 parent 415c123 commit 04ddf6d
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/build-and-test-x86.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,47 @@ jobs:
name: meson-test-logs
path: |
${{ github.workspace }}/build/meson-logs/testlog-*.txt
test-on-macos-latest:
runs-on: macos-latest
steps:
- name: install prerequisites
env:
HOMEBREW_NO_AUTO_UPDATE: 1
run: brew install meson nasm
- name: git checkout
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: cache rust toolchain
uses: actions/cache@v3
with:
path: |
~/.rustup/toolchains
~/.rustup/update-hashes
~/.rustup/settings.toml
key: ${{ runner.os }}-rust-toolchain-${{ hashFiles('rust-toolchain', 'rust-toolchain.toml') }}
- name: cache rust crates
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: cargo build for x86_64-apple-darwin
run: |
cargo build --release
- name: meson test for x86_64-apple-darwin
run: |
.github/workflows/test.sh -r ../target/release/dav1d
cp ${{ github.workspace }}/build/meson-logs/testlog.txt \
${{ github.workspace }}/build/meson-logs/testlog-x86_64-apple-darwin.txt
- name: upload build artifacts
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v3
with:
name: meson-test-logs
path: |
${{ github.workspace }}/build/meson-logs/testlog-*.txt

0 comments on commit 04ddf6d

Please sign in to comment.