-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(publish): Downgrade version-exists error to warning on dry-run
This will get cherry-picked to beta Fixes #14721
- Loading branch information
Showing
2 changed files
with
32 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -152,10 +152,19 @@ fn duplicate_version() { | |
|
||
p.cargo("publish --dry-run") | ||
.replace_crates_io(registry_dupl.index_url()) | ||
.with_status(101) | ||
.with_stderr_data(str![[r#" | ||
[UPDATING] crates.io index | ||
[ERROR] crate [email protected] already exists on crates.io index | ||
[WARNING] crate [email protected] already exists on crates.io index | ||
[WARNING] manifest has no documentation, homepage or repository. | ||
See https://doc.rust-lang.org/cargo/reference/manifest.html#package-metadata for more info. | ||
[PACKAGING] foo v0.0.1 ([ROOT]/foo) | ||
[PACKAGED] 4 files, [FILE_SIZE]B ([FILE_SIZE]B compressed) | ||
[VERIFYING] foo v0.0.1 ([ROOT]/foo) | ||
[WARNING] no edition set: defaulting to the 2015 edition while the latest is 2021 | ||
[COMPILING] foo v0.0.1 ([ROOT]/foo/target/package/foo-0.0.1) | ||
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s | ||
[UPLOADING] foo v0.0.1 ([ROOT]/foo) | ||
[WARNING] aborting upload due to dry run | ||
"#]]) | ||
.run(); | ||
|