Skip to content

Commit ae6b279

Browse files
committed
test(publish): Verify version-exists error in dry-run
1 parent 1a2df63 commit ae6b279

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

tests/testsuite/publish.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,16 @@ fn duplicate_version() {
150150
.file("src/main.rs", "fn main() {}")
151151
.build();
152152

153+
p.cargo("publish --dry-run")
154+
.replace_crates_io(registry_dupl.index_url())
155+
.with_status(101)
156+
.with_stderr_data(str![[r#"
157+
[UPDATING] crates.io index
158+
[ERROR] crate [email protected] already exists on crates.io index
159+
160+
"#]])
161+
.run();
162+
153163
p.cargo("publish")
154164
.replace_crates_io(registry_dupl.index_url())
155165
.with_status(101)

0 commit comments

Comments
 (0)