Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: Ignore missing features in tests crates #1101

Merged
merged 1 commit into from
Jul 12, 2024

Commits on Jul 10, 2024

  1. build: Ignore missing features in tests crates

    Only the crate `tests-2015` uses the feature `edition-2015`, but the code is shared with the `tests` crate.
    
    Same for `tests-no-std` which disables feature `std`, but reuses the code with the `tests` crate.
    
    Therefore the `tests`, `tests-2018` and `tests-no-std` crates should be configured to ignore the lint about missing features.
    
    Cargo clippy reports:
    ```
    warning: unexpected `cfg` condition value: `edition-2015`
     --> tests-no-std/../tests/src/build.rs:5:14
      |
    5 |     if #[cfg(feature = "edition-2015")] {
      |              ^^^^^^^-----------------
      |              |
      |              help: remove the condition
      |
      = note: no expected values for `feature`
      = help: consider adding `edition-2015` as a feature in `Cargo.toml`
      = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
      = note: `#[warn(unexpected_cfgs)]` on by default
    ```
    caspermeijn committed Jul 10, 2024
    Configuration menu
    Copy the full SHA
    be5a94e View commit details
    Browse the repository at this point in the history