Also infer parser when using --list-different (#1997)

* Also infer parser when using `--list-different`

* Add integration tests for parser inference
This commit is contained in:
Philipp Spieß authored and Christopher Chedeau committed 2017-06-06 08:24:56 -07:00
1 parent df7311a7f3
commit d679f235ed
5 files changed
+43 -1

No files matched your search

+6 -1
View File
@@ -299,7 +299,12 @@ if (stdin) {
}
if (argv["list-different"]) {
if (!prettier.check(input, options)) {
if (
!prettier.check(
input,
Object.assign({}, options, { filepath: filename })
)
) {
if (!write) {
console.log(filename);
}