prettier/tests_integration/__tests__/__snapshots__/config-resolution.js.snap

95 lines
1.7 KiB
Plaintext
Raw Normal View History

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`CLI overrides take precedence 1`] = `
"console.log(
\\"should have semi\\"
);
console.log(
\\"should not have semi\\"
)
console.log(
\\"should have semi\\"
);
function f() {
console.log(
\\"should have tab width 8\\"
);
}
\\"use strict\\";
module.exports = {
tabWidth: 8
};
function f() {
console.log(
\\"should have no semicolons\\"
)
}
function f() {
console.log(
\\"should have tab width 3\\"
);
}
function f() {
console.log.apply(
null,
[
'this file',
'should have trailing comma',
'and single quotes',
],
);
}
"
`;
exports[`accepts configuration from --config 1`] = `
"function f() {
console.log(\\"should have tab width 8\\")
}
"
`;
exports[`resolves configuration file with --find-config-path file 1`] = `
".prettierrc
"
`;
exports[`resolves configuration from external files 1`] = `
"console.log(\\"should have semi\\");
console.log(\\"should not have semi\\")
console.log(\\"should have semi\\");
function f() {
console.log(\\"should have tab width 8\\");
}
\\"use strict\\";
module.exports = {
tabWidth: 8
};
function f() {
console.log(\\"should have no semicolons\\")
}
function f() {
console.log(\\"should have tab width 3\\");
}
function f() {
console.log.apply(null, [
'this file',
'should have trailing comma',
'and single quotes',
]);
}
"
`;
exports[`resolves configuration from external files and overrides by extname 1`] = `
"function g() {
console.log(\\"should have semicolons because it has a .ts extension\\");
}
function g() {
console.log(\\"should have tab width 5 because it has .ts extension\\");
}
"
`;