From a37d6ddeadc79650d6fa8004ec26755aafd4a6fb Mon Sep 17 00:00:00 2001 From: jtmoon79 <815261+jtmoon79@users.noreply.github.com> Date: Sun, 28 May 2023 19:09:43 -0700 Subject: [PATCH] yamllint cleanup lint.yml test.yml NFC fix most `yamllint` errors and warnings in `lint.yml` and `test.yml`. --- .github/workflows/lint.yml | 15 +++++++++++---- .github/workflows/test.yml | 31 +++++++++++++++++++++++++------ 2 files changed, 36 insertions(+), 10 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 9f52f477e4..b199dd3c9a 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,3 +1,5 @@ +# lint.yml +--- name: lint on: @@ -18,16 +20,20 @@ jobs: - run: cargo fmt --check -- --color=always - run: cargo fmt --check --manifest-path fuzz/Cargo.toml - run: cargo clippy --color=always -- -D warnings - - run: cargo clippy --color=always --target x86_64-pc-windows-msvc -- -D warnings - - run: cargo clippy --manifest-path fuzz/Cargo.toml --color=always -- -D warnings + - run: | + cargo clippy --color=always --target x86_64-pc-windows-msvc \ + -- -D warnings + - run: | + cargo clippy --manifest-path fuzz/Cargo.toml --color=always \ + -- -D warnings env: RUSTFLAGS: "-Dwarnings" cargo-deny: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: EmbarkStudios/cargo-deny-action@v1 + - uses: actions/checkout@v3 + - uses: EmbarkStudios/cargo-deny-action@v1 check-doc: runs-on: ubuntu-latest @@ -39,3 +45,4 @@ jobs: - run: cargo doc --all-features --no-deps env: RUSTDOCFLAGS: -Dwarnings +... diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a18e07aaf0..7659c34435 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,3 +1,5 @@ +# test.yml +--- name: All Tests and Builds on: @@ -45,9 +47,18 @@ jobs: with: toolchain: 1.56.1 - uses: Swatinem/rust-cache@v2 - # run --lib and --doc to avoid the long running integration tests which are run elsewhere - - run: cargo test --lib --features unstable-locales,wasmbind,oldtime,clock,rustc-serialize,winapi,serde --color=always -- --color=always - - run: cargo test --doc --features unstable-locales,wasmbind,oldtime,clock,rustc-serialize,winapi,serde --color=always -- --color=always + # run --lib and --doc to avoid the long running integration tests + # which are run elsewhere + - run: | + cargo test --lib \ + --features \ + unstable-locales,wasmbind,oldtime,clock,rustc-serialize,winapi,serde \ + --color=always -- --color=always + - run: | + cargo test --doc \ + --features \ + unstable-locales,wasmbind,oldtime,clock,rustc-serialize,winapi,serde \ + --color=always -- --color=always rust_versions: strategy: @@ -63,7 +74,8 @@ jobs: - uses: Swatinem/rust-cache@v2 - run: cargo check --benches - run: cargo check --manifest-path fuzz/Cargo.toml --all-targets - # run --lib and --doc to avoid the long running integration tests which are run elsewhere + # run --lib and --doc to avoid the long running integration tests + # which are run elsewhere - run: cargo test --lib --all-features --color=always -- --color=always - run: cargo test --doc --all-features --color=always -- --color=always @@ -77,7 +89,10 @@ jobs: - uses: dtolnay/rust-toolchain@stable - uses: taiki-e/install-action@cargo-hack - uses: Swatinem/rust-cache@v2 - - run: cargo hack check --feature-powerset --optional-deps serde,rkyv --skip default --skip __internal_bench --skip __doctest --skip iana-time-zone --skip pure-rust-locales + - run: | + cargo hack check --feature-powerset --optional-deps serde,rkyv \ + --skip default --skip __internal_bench --skip __doctest \ + --skip iana-time-zone --skip pure-rust-locales - run: cargo test --lib --no-default-features - run: cargo test --doc --no-default-features @@ -136,7 +151,10 @@ jobs: targets: wasm32-unknown-unknown - uses: taiki-e/install-action@cargo-hack - uses: Swatinem/rust-cache@v2 - - run: cargo hack check --feature-powerset --optional-deps serde,rkyv --skip default --skip __internal_bench --skip __doctest --skip iana-time-zone --skip pure-rust-locales + - run: | + cargo hack check --feature-powerset --optional-deps serde,rkyv \ + --skip default --skip __internal_bench --skip __doctest \ + --skip iana-time-zone --skip pure-rust-locales cross-targets: strategy: @@ -158,3 +176,4 @@ jobs: - run: cargo +nightly doc --all-features --no-deps env: RUSTDOCFLAGS: "-D warnings --cfg docsrs" +...