diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 30c7e10622..59fbed3e36 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -98,11 +98,10 @@ jobs: override: true - name: Install cargo-web - # uses: actions-rs/install@v0.1 - # with: - # crate: cargo-web - # version: ^0.6 - # use-tool-cache: true + uses: actions-rs/install@v0.1 + with: + crate: cargo-web + use-tool-cache: true run: cargo +stable install cargo-web if: steps.cache.outputs.cache-hit != 'true' @@ -187,17 +186,22 @@ jobs: target key: ${{ runner.os }}-cargo-${{ matrix.rust }}-${{ matrix.os }}-${{ hashFiles('**/Cargo.toml') }}2 - - name: Test feature powerset (--tests) + # For speed reasons, it's worth it to just check the feature powerset and + # test with everything enabled. As features are additive, the tests ensure + # that everything works, while the checking ensures any combination would + # compile without issue. + + - name: Check feature powerset uses: actions-rs/cargo@v1 with: command: hack - args: test --feature-powerset --optional-deps --skip default,libc,winapi,stdweb --tests + args: check --feature-powerset --optional-deps --skip default,libc,winapi,stdweb - - name: Test documentation + - name: Test (--all-features) uses: actions-rs/cargo@v1 with: command: test - args: --all-features --doc + args: --all-features fmt: name: Formatting diff --git a/time-macros-impl/src/error.rs b/time-macros-impl/src/error.rs index b5c9bd2d7f..9a74f4aa13 100644 --- a/time-macros-impl/src/error.rs +++ b/time-macros-impl/src/error.rs @@ -11,8 +11,8 @@ pub(crate) enum Error { Custom(String), } +#[allow(clippy::use_self)] impl fmt::Display for Error { - #[allow(clippy::use_self)] fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { match self { Error::MissingComponent { name } => write!(f, "missing component: {}", name),