Skip to content

Commit b969617

Browse files
committed
test: Ensure we don't rely on unit return values
This will allow changing `Execs::run` return type
1 parent 69e5959 commit b969617

12 files changed

+31
-31
lines changed

tests/testsuite/build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ fn build_with_symlink_to_path_dependency_with_build_script_in_git() {
8282
// It is necessary to have a sub-repository and to add files so there is an index.
8383
let repo = git::init(&root.join("original"));
8484
git::add(&repo);
85-
cargo_process("build").run()
85+
cargo_process("build").run();
8686
}
8787

8888
#[cargo_test]

tests/testsuite/build_script.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5234,7 +5234,7 @@ fn dev_dep_with_links() {
52345234
.file("bar/build.rs", "fn main() {}")
52355235
.file("bar/src/lib.rs", "")
52365236
.build();
5237-
p.cargo("check --tests").run()
5237+
p.cargo("check --tests").run();
52385238
}
52395239

52405240
#[cargo_test]

tests/testsuite/config.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1640,7 +1640,7 @@ fn cargo_target_empty_env() {
16401640
16411641
"#]])
16421642
.with_status(101)
1643-
.run()
1643+
.run();
16441644
}
16451645

16461646
#[cargo_test]

tests/testsuite/future_incompat_report.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -453,5 +453,5 @@ big_update v1.0.0 has the following newer versions available: 2.0.0
453453
with_updates v1.0.0 has the following newer versions available: 1.0.1, 1.0.2, 3.0.1
454454
...
455455
"#]])
456-
.run()
456+
.run();
457457
}

tests/testsuite/metadata.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3401,7 +3401,7 @@ fn metadata_links() {
34013401
"#]]
34023402
.is_json(),
34033403
)
3404-
.run()
3404+
.run();
34053405
}
34063406

34073407
#[cargo_test]

tests/testsuite/open_namespaces.rs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Caused by:
3131
See https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#open-namespaces for more information about the status of this feature.
3232
3333
"#]])
34-
.run()
34+
.run();
3535
}
3636

3737
#[cargo_test]
@@ -100,7 +100,7 @@ fn implicit_lib_within_namespace() {
100100
.is_json(),
101101
)
102102
.with_stderr_data("")
103-
.run()
103+
.run();
104104
}
105105

106106
#[cargo_test]
@@ -169,7 +169,7 @@ fn implicit_bin_within_namespace() {
169169
.is_json(),
170170
)
171171
.with_stderr_data("")
172-
.run()
172+
.run();
173173
}
174174

175175
#[cargo_test]
@@ -256,7 +256,7 @@ fn explicit_bin_within_namespace() {
256256
.is_json(),
257257
)
258258
.with_stderr_data("")
259-
.run()
259+
.run();
260260
}
261261

262262
#[cargo_test]
@@ -354,7 +354,7 @@ path+[ROOTURL]/foo#foo::[email protected]
354354
355355
"#]])
356356
.with_stderr_data("")
357-
.run()
357+
.run();
358358
}
359359

360360
#[cargo_test]
@@ -384,7 +384,7 @@ fn update_spec_accepts_namespaced_name() {
384384
[LOCKING] 0 packages to latest compatible versions
385385
386386
"#]])
387-
.run()
387+
.run();
388388
}
389389

390390
#[cargo_test]
@@ -414,7 +414,7 @@ fn update_spec_accepts_namespaced_pkgid() {
414414
[LOCKING] 0 packages to latest compatible versions
415415
416416
"#]])
417-
.run()
417+
.run();
418418
}
419419

420420
#[cargo_test]

tests/testsuite/package.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3923,7 +3923,7 @@ See https://doc.rust-lang.org/cargo/reference/manifest.html#package-metadata for
39233923
[PACKAGED] 6 files, [FILE_SIZE]B ([FILE_SIZE]B compressed)
39243924
39253925
"#]])
3926-
.run()
3926+
.run();
39273927
}
39283928

39293929
#[cargo_test]

tests/testsuite/pkgid.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,5 +403,5 @@ fn pkgid_json_message_metadata_consistency() {
403403
"#]]
404404
.is_json(),
405405
)
406-
.run()
406+
.run();
407407
}

tests/testsuite/precise_pre_release.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ if you are looking for the prerelease package it needs to be specified explicitl
3939
perhaps a crate was updated and forgotten to be re-vendored?
4040
4141
"#]])
42-
.run()
42+
.run();
4343
}
4444

4545
#[cargo_test]

tests/testsuite/pub_priv.rs

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ fn exported_priv_warning() {
4242
src/lib.rs:3:13: [WARNING] type `FromPriv` from private dependency 'priv_dep' in public interface
4343
...
4444
"#]])
45-
.run()
45+
.run();
4646
}
4747

4848
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -87,7 +87,7 @@ fn exported_pub_dep() {
8787
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
8888
8989
"#]])
90-
.run()
90+
.run();
9191
}
9292

9393
#[cargo_test]
@@ -113,7 +113,7 @@ Caused by:
113113
See https://doc.rust-lang.org/[..]cargo/reference/unstable.html#public-dependency for more information about using this feature.
114114
115115
"#]])
116-
.run()
116+
.run();
117117
}
118118

119119
#[cargo_test]
@@ -151,7 +151,7 @@ fn requires_feature() {
151151
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
152152
153153
"#]])
154-
.run()
154+
.run();
155155
}
156156

157157
#[cargo_test]
@@ -194,7 +194,7 @@ Caused by:
194194
'public' specifier can only be used on regular dependencies, not dev-dependencies
195195
196196
"#]])
197-
.run()
197+
.run();
198198
}
199199

200200
#[cargo_test]
@@ -233,7 +233,7 @@ fn pub_dev_dependency_without_feature() {
233233
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
234234
235235
"#]])
236-
.run()
236+
.run();
237237
}
238238

239239
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -291,7 +291,7 @@ Caused by:
291291
foo2 is public, but workspace dependencies cannot be public
292292
293293
"#]])
294-
.run()
294+
.run();
295295
}
296296

297297
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -336,7 +336,7 @@ fn allow_priv_in_tests() {
336336
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
337337
338338
"#]])
339-
.run()
339+
.run();
340340
}
341341

342342
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -381,7 +381,7 @@ fn allow_priv_in_benchs() {
381381
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
382382
383383
"#]])
384-
.run()
384+
.run();
385385
}
386386

387387
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -427,7 +427,7 @@ fn allow_priv_in_bins() {
427427
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
428428
429429
"#]])
430-
.run()
430+
.run();
431431
}
432432

433433
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -473,7 +473,7 @@ fn allow_priv_in_examples() {
473473
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
474474
475475
"#]])
476-
.run()
476+
.run();
477477
}
478478

479479
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -520,7 +520,7 @@ fn allow_priv_in_custom_build() {
520520
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
521521
522522
"#]])
523-
.run()
523+
.run();
524524
}
525525

526526
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]
@@ -576,7 +576,7 @@ fn publish_package_with_public_dependency() {
576576
[FINISHED] `dev` profile [unoptimized + debuginfo] target(s) in [ELAPSED]s
577577
578578
"#]])
579-
.run()
579+
.run();
580580
}
581581

582582
#[cargo_test(nightly, reason = "exported_private_dependencies lint is unstable")]

tests/testsuite/registry.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3242,7 +3242,7 @@ fn protocol() {
32423242
[ERROR] unsupported registry protocol `invalid` (defined in environment variable `CARGO_REGISTRIES_CRATES_IO_PROTOCOL`)
32433243
32443244
"#]])
3245-
.run()
3245+
.run();
32463246
}
32473247

32483248
#[cargo_test]
@@ -3253,7 +3253,7 @@ fn http_requires_trailing_slash() {
32533253
[ERROR] sparse registry url must end in a slash `/`: sparse+https://invalid.crates.io/test
32543254
32553255
"#]])
3256-
.run()
3256+
.run();
32573257
}
32583258

32593259
// Limit the test to debug builds so that `__CARGO_TEST_MAX_UNPACK_SIZE` will take affect.

tests/testsuite/test.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4307,7 +4307,7 @@ fn test_hint_workspace_virtual() {
43074307
43084308
"#]])
43094309
.with_status(101)
4310-
.run()
4310+
.run();
43114311
}
43124312

43134313
#[cargo_test]

0 commit comments

Comments
 (0)