Skip to content

Commit b420a82

Browse files
committed
test: Migrate to pretty jsonlines for bad_manifest_path tests
1 parent d293f7e commit b420a82

File tree

1 file changed

+28
-12
lines changed

1 file changed

+28
-12
lines changed

tests/testsuite/bad_manifest_path.rs

Lines changed: 28 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -331,10 +331,14 @@ fn verify_project_dir_containing_cargo_toml() {
331331
.with_status(1)
332332
.with_stdout_data(
333333
str![[r#"
334-
{"invalid":"the manifest-path must be a path to a Cargo.toml file"}
335-
334+
[
335+
{
336+
"invalid": "the manifest-path must be a path to a Cargo.toml file"
337+
}
338+
]
336339
"#]]
337-
.is_jsonlines(),
340+
.is_json()
341+
.against_jsonlines(),
338342
)
339343
.run();
340344
}
@@ -351,10 +355,14 @@ fn verify_project_dir_plus_file() {
351355
.with_status(1)
352356
.with_stdout_data(
353357
str![[r#"
354-
{"invalid":"the manifest-path must be a path to a Cargo.toml file"}
355-
358+
[
359+
{
360+
"invalid": "the manifest-path must be a path to a Cargo.toml file"
361+
}
362+
]
356363
"#]]
357-
.is_jsonlines(),
364+
.is_json()
365+
.against_jsonlines(),
358366
)
359367
.run();
360368
}
@@ -371,10 +379,14 @@ fn verify_project_dir_plus_path() {
371379
.with_status(1)
372380
.with_stdout_data(
373381
str![[r#"
374-
{"invalid":"the manifest-path must be a path to a Cargo.toml file"}
375-
382+
[
383+
{
384+
"invalid": "the manifest-path must be a path to a Cargo.toml file"
385+
}
386+
]
376387
"#]]
377-
.is_jsonlines(),
388+
.is_json()
389+
.against_jsonlines(),
378390
)
379391
.run();
380392
}
@@ -387,10 +399,14 @@ fn verify_project_dir_to_nonexistent_cargo_toml() {
387399
.with_status(1)
388400
.with_stdout_data(
389401
str![[r#"
390-
{"invalid":"manifest path `foo/bar/baz/Cargo.toml` does not exist"}
391-
402+
[
403+
{
404+
"invalid": "manifest path `foo/bar/baz/Cargo.toml` does not exist"
405+
}
406+
]
392407
"#]]
393-
.is_jsonlines(),
408+
.is_json()
409+
.against_jsonlines(),
394410
)
395411
.run();
396412
}

0 commit comments

Comments
 (0)