refactor: replace cfg_if with cfg_select (#925)
#120
This file contains hidden or 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
| name: TestExecutor | |
| on: | |
| merge_group: | |
| types: [checks_requested] | |
| push: | |
| branches: | |
| - master | |
| paths: | |
| - 'compio-executor/**/*.rs' | |
| - 'compio-executor/Cargo.toml' | |
| - 'Cargo.toml' | |
| - '.github/workflows/ci_test_executor.yml' | |
| pull_request: | |
| branches: | |
| - master | |
| paths: | |
| - 'compio-executor/**/*.rs' | |
| - 'compio-executor/Cargo.toml' | |
| - 'Cargo.toml' | |
| - '.github/workflows/ci_test_executor.yml' | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }} | |
| cancel-in-progress: true | |
| env: | |
| RUST_BACKTRACE: 1 | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| test_executor: | |
| strategy: | |
| matrix: | |
| setup: | |
| - os: 'ubuntu-24.04' | |
| - os: 'ubuntu-24.04-arm' | |
| - os: 'windows-latest' | |
| target: 'x86_64-pc-windows-msvc' | |
| - os: 'windows-latest' | |
| target: 'x86_64-pc-windows-gnu' | |
| - os: 'macos-14' | |
| - os: 'macos-15' | |
| runs-on: ${{ matrix.setup.os }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup Rust Toolchain | |
| run: | | |
| rustup toolchain install nightly -c miri -c rust-src | |
| rustup override set nightly | |
| - name: Setup target | |
| if: ${{ matrix.setup.target }} | |
| run: rustup target install ${{ matrix.setup.target }} | |
| - uses: taiki-e/install-action@nextest | |
| - name: Test loom on ${{ matrix.setup.os }} nightly ${{ matrix.setup.target }} | |
| shell: bash | |
| run: | | |
| set -ex | |
| cargo miri test \ | |
| -p compio-executor \ | |
| --test executor | |
| RUSTFLAGS="--cfg loom" \ | |
| LOOM_LOCATION=1 \ | |
| LOOM_LOG=info,compio_executor=trace \ | |
| cargo nextest run \ | |
| --profile loom \ | |
| --features enable_log \ | |
| -p compio-executor |