mirror of
https://github.com/denoland/deno.git
synced 2024-12-23 07:44:48 -05:00
chore: move fmt test to integration tests (#6340)
This commit is contained in:
parent
e60922981b
commit
097e42418c
3 changed files with 8 additions and 8 deletions
|
@ -324,11 +324,3 @@ fn test_is_supported() {
|
||||||
assert!(is_supported(Path::new("foo.mjs")));
|
assert!(is_supported(Path::new("foo.mjs")));
|
||||||
assert!(!is_supported(Path::new("foo.mjsx")));
|
assert!(!is_supported(Path::new("foo.mjsx")));
|
||||||
}
|
}
|
||||||
|
|
||||||
#[tokio::test]
|
|
||||||
async fn check_tests_dir() {
|
|
||||||
// Because of cli/tests/error_syntax.js the following should fail but not
|
|
||||||
// crash.
|
|
||||||
let r = format(vec!["./tests".to_string()], true).await;
|
|
||||||
assert!(r.is_err());
|
|
||||||
}
|
|
||||||
|
|
2
cli/tests/fmt_check_tests_dir.out
Normal file
2
cli/tests/fmt_check_tests_dir.out
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
[WILDCARD]
|
||||||
|
error: Found [WILDCARD] not formatted files
|
|
@ -1539,6 +1539,12 @@ itest!(bundle {
|
||||||
output: "bundle.test.out",
|
output: "bundle.test.out",
|
||||||
});
|
});
|
||||||
|
|
||||||
|
itest!(fmt_check_tests_dir {
|
||||||
|
args: "fmt --check ./",
|
||||||
|
output: "fmt_check_tests_dir.out",
|
||||||
|
exit_code: 1,
|
||||||
|
});
|
||||||
|
|
||||||
itest!(fmt_stdin {
|
itest!(fmt_stdin {
|
||||||
args: "fmt -",
|
args: "fmt -",
|
||||||
input: Some("const a = 1\n"),
|
input: Some("const a = 1\n"),
|
||||||
|
|
Loading…
Reference in a new issue