diff options
| author | bors <bors@rust-lang.org> | 2022-07-21 07:58:27 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-07-21 07:58:27 +0000 |
| commit | bc903cd3c2f6c45a680c70225c0fb851856256a8 (patch) | |
| tree | 6911e68d79d91572faec4065e9cb5066aa7c043b /tests/codegen/src-hash-algorithm/src-hash-algorithm-sha256.rs | |
| parent | d017e2dacd3306a892f08d1e53dc8cb892b743b4 (diff) | |
| parent | 5b3300dc29c8ccce3e34ac37d5b79e5ca1b5e4c1 (diff) | |
| download | rust-bc903cd3c2f6c45a680c70225c0fb851856256a8.tar.gz rust-bc903cd3c2f6c45a680c70225c0fb851856256a8.zip | |
Auto merge of #9216 - smoelius:master, r=flip1995
Add `ui_cargo_toml_metadata` test This PR adds a test to check the metadata of packages in the `ui_cargo` directory. A recent change to Cargo causes it to warn when it finds multiple packages with the same name in a git dependency (the issue is described [here](https://github.com/rust-lang/cargo/issues/10752)). Many (if not all) Dylint libraries depend upon `clippy_utils`. As a result of the change, one now sees the following when building a Dylint library: ``` warning: skipping duplicate package `fail` found at `/home/smoelius/.cargo/git/checkouts/rust-clippy-4b72815e96774b3d/0cb0f76/tests/ui-cargo/module_style/pass_mod` warning: skipping duplicate package `fail` found at `/home/smoelius/.cargo/git/checkouts/rust-clippy-4b72815e96774b3d/0cb0f76/tests/ui-cargo/module_style/fail_no_mod` warning: skipping duplicate package `cargo_common_metadata` found at `/home/smoelius/.cargo/git/checkouts/rust-clippy-4b72815e96774b3d/0cb0f76/tests/ui-cargo/cargo_common_metadata/fail_publish_true` warning: skipping duplicate package `fail-cargo` found at `/home/smoelius/.cargo/git/checkouts/rust-clippy-4b72815e96774b3d/0cb0f76/tests/ui-cargo/cargo_rust_version/pass_cargo` warning: skipping duplicate package `fail-clippy` found at `/home/smoelius/.cargo/git/checkouts/rust-clippy-4b72815e96774b3d/0cb0f76/tests/ui-cargo/cargo_rust_version/fail_clippy` warning: skipping duplicate package `fail-both-same` found at `/home/smoelius/.cargo/git/checkouts/rust-clippy-4b72815e96774b3d/0cb0f76/tests/ui-cargo/cargo_rust_version/fail_both_same` warning: skipping duplicate package `fail-file-attr` found at `/home/smoelius/.cargo/git/checkouts/rust-clippy-4b72815e96774b3d/0cb0f76/tests/ui-cargo/cargo_rust_version/fail_file_attr` ``` There appear to be two contributing factors: - Some packages in `ui_cargo` could have a `publish = false` added to them. - Some packages in `ui_cargo` seem to be inconsistently named. The new test checks that each package in the `ui_cargo` directory has a name matching one of its parent directories, and `publish = false` in its metadata (with a few exceptions). Note that the packages in `cargo_common_metadata` require special care because `publish` is the subject of some of the `cargo_common_metadata` tests. Also note that this PR adds `walkdir` as a dev dependency to the `clippy` package. However, it was already a dependency of `clippy_dev` and `lintcheck`. So hopefully this is acceptable. Our continued thanks for making `clippy_utils` available, BTW. :) r? `@flip1995` changelog: none
Diffstat (limited to 'tests/codegen/src-hash-algorithm/src-hash-algorithm-sha256.rs')
0 files changed, 0 insertions, 0 deletions
