mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-03-31 09:45:31 +00:00
47 lines
1.1 KiB
YAML
47 lines
1.1 KiB
YAML
name: 'cargo: build and test'
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
pull_request:
|
|
branches: [ master ]
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
|
|
jobs:
|
|
build-test-linux:
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 20
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Install latest stable Rust
|
|
uses: actions-rs/toolchain@v1
|
|
with:
|
|
profile: minimal
|
|
toolchain: stable
|
|
override: true
|
|
- name: Install dependencies
|
|
run: sudo apt-get update -y && sudo apt-get install libhwloc-dev -y
|
|
- name: Build
|
|
run: |
|
|
cargo build --verbose -p aquatic_udp --features "cpu-pinning"
|
|
cargo build --verbose -p aquatic_http
|
|
cargo build --verbose -p aquatic_ws
|
|
- name: Run tests
|
|
run: cargo test --verbose --workspace --all-targets
|
|
|
|
|
|
build-macos:
|
|
runs-on: macos-latest
|
|
timeout-minutes: 10
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Install latest stable Rust
|
|
uses: actions-rs/toolchain@v1
|
|
with:
|
|
profile: minimal
|
|
toolchain: stable
|
|
override: true
|
|
- name: Build
|
|
run: cargo build --verbose -p aquatic_udp
|