|
@@ -0,0 +1,50 @@
|
|
|
|
|
+name: Unit tests BSD
|
|
|
|
|
+
|
|
|
|
|
+on:
|
|
|
|
|
+ push:
|
|
|
|
|
+ branches: [ main ]
|
|
|
|
|
+ paths:
|
|
|
|
|
+ - '.github/workflows/unit-tests-bsd.yml'
|
|
|
|
|
+ - 'src/**'
|
|
|
|
|
+ - 'Cargo.*'
|
|
|
|
|
+ - build.rs
|
|
|
|
|
+ pull_request:
|
|
|
|
|
+ branches: [ main ]
|
|
|
|
|
+ paths:
|
|
|
|
|
+ - '.github/workflows/unit-tests-bsd.yml'
|
|
|
|
|
+ - 'src/**'
|
|
|
|
|
+ - 'Cargo.*'
|
|
|
|
|
+ - build.rs
|
|
|
|
|
+
|
|
|
|
|
+concurrency:
|
|
|
|
|
+ group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
|
|
|
|
|
+ cancel-in-progress: true
|
|
|
|
|
+
|
|
|
|
|
+jobs:
|
|
|
|
|
+ unit-tests-netbsd:
|
|
|
|
|
+ runs-on: ubuntu-22.04
|
|
|
|
|
+ timeout-minutes: 20
|
|
|
|
|
+ steps:
|
|
|
|
|
+ - uses: actions/checkout@v4
|
|
|
|
|
+ with:
|
|
|
|
|
+ submodules: recursive
|
|
|
|
|
+ - name: Compile
|
|
|
|
|
+ uses: vmactions/netbsd-vm@v1
|
|
|
|
|
+ with:
|
|
|
|
|
+ release: '9.3'
|
|
|
|
|
+ usesh: true
|
|
|
|
|
+ prepare: |
|
|
|
|
|
+ PATH="/root/.cargo/bin:/usr/pkg/sbin:/usr/pkg/bin:$PATH"
|
|
|
|
|
+ PKG_PATH="https://ftp.netbsd.org/pub/pkgsrc/packages/NetBSD/amd64/9.3/All/"
|
|
|
|
|
+ export PATH PKG_PATH
|
|
|
|
|
+ /usr/sbin/pkg_add pkgin
|
|
|
|
|
+ pkgin -y install rust git
|
|
|
|
|
+ cargo install cargo-hack
|
|
|
|
|
+ git config --global --add safe.directory /home/runner/work/eza/eza
|
|
|
|
|
+ run: |
|
|
|
|
|
+ set -e
|
|
|
|
|
+ export CARGO_TERM_COLOR="always"
|
|
|
|
|
+ export RUSTFLAGS="--deny warnings"
|
|
|
|
|
+ cargo fmt --check
|
|
|
|
|
+ cargo clippy -- -D warnings
|
|
|
|
|
+ cargo hack test
|