name: build/test
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
linux:
runs-on: ubuntu-22.04
name: Ubuntu
steps:
- uses: actions/checkout@v3
- name: Prepare
run: git submodule update --init
- name: Build
run: cargo build --verbose --features userfaultfd,sanity
- name: Run tests
run: cargo test --verbose --features userfaultfd,sanity
macos:
runs-on: macOS-13
name: macOS
steps:
- uses: actions-rs/toolchain@v1
with:
profile: default
toolchain: nightly
- uses: actions/checkout@v3
- name: Prepare
run: git submodule update --init
- name: Install
run: rustup toolchain install nightly --component clippy
- name: Clippy
run: cargo clippy
- name: Build
run: cargo build --verbose --features sanity
- name: Run tests
run: cargo test --verbose --features sanity
freebsd:
runs-on: ubuntu-22.04
name: FreeBSD
steps:
- uses: actions/checkout@v3
- name: FreeBSD CI
id: test
uses: vmactions/freebsd-vm@v1
with:
usesh: true
sync: rsync
copyback: false
mem: 2048
release: 13.2
prepare: |
pkg install -y curl bash sudo
curl https://sh.rustup.rs -sSf | sh -s -- -y
run: |
freebsd-version
. "$HOME/.cargo/env"
rustup toolchain install nightly
git submodule update --init
cargo build --verbose --features sanity
cargo test --verbose --features sanity