From 857f9b32e02c876e9cce6e82f82fb6ed95248646 Mon Sep 17 00:00:00 2001 From: Yusuke Tanaka Date: Wed, 9 Sep 2020 23:45:31 +0900 Subject: feat(fmt, lint): show number of checked files (#7312) --- cli/tests/fmt/expected_fmt_check_formatted_files.out | 1 + cli/tests/fmt/expected_fmt_check_ignore.out | 1 + cli/tests/fmt/expected_fmt_check_tests_dir.out | 2 ++ cli/tests/fmt/expected_fmt_check_verbose_formatted_files.out | 1 + cli/tests/fmt/expected_fmt_check_verbose_tests_dir.out | 2 ++ cli/tests/fmt/formatted1.js | 5 +++++ cli/tests/fmt/formatted2.ts | 5 +++++ 7 files changed, 17 insertions(+) create mode 100644 cli/tests/fmt/expected_fmt_check_formatted_files.out create mode 100644 cli/tests/fmt/expected_fmt_check_ignore.out create mode 100644 cli/tests/fmt/expected_fmt_check_tests_dir.out create mode 100644 cli/tests/fmt/expected_fmt_check_verbose_formatted_files.out create mode 100644 cli/tests/fmt/expected_fmt_check_verbose_tests_dir.out create mode 100644 cli/tests/fmt/formatted1.js create mode 100644 cli/tests/fmt/formatted2.ts (limited to 'cli/tests/fmt') diff --git a/cli/tests/fmt/expected_fmt_check_formatted_files.out b/cli/tests/fmt/expected_fmt_check_formatted_files.out new file mode 100644 index 000000000..158c556c2 --- /dev/null +++ b/cli/tests/fmt/expected_fmt_check_formatted_files.out @@ -0,0 +1 @@ +Checked 2 files diff --git a/cli/tests/fmt/expected_fmt_check_ignore.out b/cli/tests/fmt/expected_fmt_check_ignore.out new file mode 100644 index 000000000..c05ac45a1 --- /dev/null +++ b/cli/tests/fmt/expected_fmt_check_ignore.out @@ -0,0 +1 @@ +Checked 1 file diff --git a/cli/tests/fmt/expected_fmt_check_tests_dir.out b/cli/tests/fmt/expected_fmt_check_tests_dir.out new file mode 100644 index 000000000..04cd5ec64 --- /dev/null +++ b/cli/tests/fmt/expected_fmt_check_tests_dir.out @@ -0,0 +1,2 @@ +[WILDCARD] +error: Found 1 not formatted file in [WILDCARD] files diff --git a/cli/tests/fmt/expected_fmt_check_verbose_formatted_files.out b/cli/tests/fmt/expected_fmt_check_verbose_formatted_files.out new file mode 100644 index 000000000..158c556c2 --- /dev/null +++ b/cli/tests/fmt/expected_fmt_check_verbose_formatted_files.out @@ -0,0 +1 @@ +Checked 2 files diff --git a/cli/tests/fmt/expected_fmt_check_verbose_tests_dir.out b/cli/tests/fmt/expected_fmt_check_verbose_tests_dir.out new file mode 100644 index 000000000..04cd5ec64 --- /dev/null +++ b/cli/tests/fmt/expected_fmt_check_verbose_tests_dir.out @@ -0,0 +1,2 @@ +[WILDCARD] +error: Found 1 not formatted file in [WILDCARD] files diff --git a/cli/tests/fmt/formatted1.js b/cli/tests/fmt/formatted1.js new file mode 100644 index 000000000..587aa5b96 --- /dev/null +++ b/cli/tests/fmt/formatted1.js @@ -0,0 +1,5 @@ +function foo() { + return 42; +} + +foo(); diff --git a/cli/tests/fmt/formatted2.ts b/cli/tests/fmt/formatted2.ts new file mode 100644 index 000000000..4a8036806 --- /dev/null +++ b/cli/tests/fmt/formatted2.ts @@ -0,0 +1,5 @@ +function bar(): number { + return 42; +} + +bar(); -- cgit v1.2.3