Skip to content

Add best_backup_generic helper in path_selection #684

Add best_backup_generic helper in path_selection

Add best_backup_generic helper in path_selection #684

Workflow file for this run

name: ci
on: [push, pull_request]
jobs:
test:
name: test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
rust: [1.71, stable, beta]
steps:
- name: Checkout repository
uses: actions/checkout@v1
- name: Install Rust
uses: hecrj/setup-rust-action@v1
with:
rust-version: ${{ matrix.rust }}
# Clippy.
#
# We run Clippy for stable and beta only, to minimize the possibility of a
# lint requiring something in the MSRV but the opposite thing in stable,
# or vice versa.
#
# For stable, error out on warnings.
- if: matrix.rust == 'stable'
run: |
rustup component add clippy
cargo clippy --all --all-features -- -D warnings -W clippy::cargo
- if: matrix.rust == 'beta'
run: rustup component add clippy
# For beta, turn warnings into GitHub annotations.
- if: matrix.rust == 'beta'
uses: mathiasvr/command-output@v2.0.0
id: clippy_beta
with:
run: |
# We can warn on additional lints. cargo::nursery might make sense.
# XXX currently this only shows the first line of output. Also see
# https://github.com/actions/toolkit/issues/193
# Replacing '\n' with "%0A" might be a workaround.
cargo clippy --all --all-features -q --message-format short -- \
-W clippy::cargo # -W clippy::nursery
- if: ${{ steps.clippy_beta.outputs.stderr }}
env:
clippy_warnings: ${{ steps.clippy_beta.outputs.stderr }}
run: echo "::warning ::$clippy_warnings"
# Because of all the features, we run build and test twice -- once with
# full features and once without any features at all -- to make it more
# likely that everything works.
# Build
- run: cargo build --verbose --all --all-features
- run: cargo build --verbose --all
# Test
- run: cargo test --verbose --all --all-features
- run: cargo test --verbose --all
# Test using minimal dependency versions from Cargo.toml
- if: matrix.rust != 'beta'
run: |
rustup toolchain install nightly
cargo +nightly update -Z minimal-versions
cargo build --verbose --all --all-features
cargo test --verbose --all --all-features
name: Check and test with minimal-versions