prettier/tests_integration/__tests__/__snapshots__/with-config-precedence.js.snap

163 lines
3.3 KiB
Plaintext

// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`CLI overrides are still applied when no config is found with --config-precedence file-override 1`] = `
"function noConfigJs() {
console.log(\\"no-config/file.js should have no semicolons\\")
}
"
`;
exports[`CLI overrides gets applied when no config exists with --config-precedence prefer-file 1`] = `
"function noConfigJs() {
console.log(
\\"no-config/file.js should have no semicolons\\"
);
}
"
`;
exports[`CLI overrides gets ignored when config exists with --config-precedence prefer-file 1`] = `
"function js() {
console.log(\\"js/file.js should have tab width 8\\");
}
\\"use strict\\";
module.exports = {
tabWidth: 8
};
"
`;
exports[`CLI overrides take lower precedence with --config-precedence file-override 1`] = `
"function js() {
console.log(\\"js/file.js should have tab width 8\\");
}
\\"use strict\\";
module.exports = {
tabWidth: 8
};
"
`;
exports[`CLI overrides take precedence with --config-precedence cli-override 1`] = `
"console.log(
\\"jest/__best-tests__/file.js should have semi\\"
);
console.log(
\\"jest/Component.js should not have semi\\"
)
console.log(
\\"jest/Component.test.js should have semi\\"
);
function js() {
console.log(
\\"js/file.js should have tab width 8\\"
);
}
\\"use strict\\";
module.exports = {
tabWidth: 8
};
function noConfigJs() {
console.log(
\\"no-config/file.js should have no semicolons\\"
)
}
function packageJs() {
console.log(
\\"package/file.js should have tab width 3\\"
);
}
function rcJson() {
console.log.apply(
null,
[
'rc-json/file.js',
'should have trailing comma',
'and single quotes',
],
);
}
function rcYaml() {
console.log.apply(
null,
[
'rc-yaml/file.js',
'should have trailing comma',
'and single quotes',
],
);
}
"
`;
exports[`CLI overrides take precedence without --config-precedence 1`] = `
"console.log(
\\"jest/__best-tests__/file.js should have semi\\"
);
console.log(
\\"jest/Component.js should not have semi\\"
)
console.log(
\\"jest/Component.test.js should have semi\\"
);
function js() {
console.log(
\\"js/file.js should have tab width 8\\"
);
}
\\"use strict\\";
module.exports = {
tabWidth: 8
};
function noConfigJs() {
console.log(
\\"no-config/file.js should have no semicolons\\"
)
}
function packageJs() {
console.log(
\\"package/file.js should have tab width 3\\"
);
}
function rcJson() {
console.log.apply(
null,
[
'rc-json/file.js',
'should have trailing comma',
'and single quotes',
],
);
}
function rcYaml() {
console.log.apply(
null,
[
'rc-yaml/file.js',
'should have trailing comma',
'and single quotes',
],
);
}
"
`;
exports[`CLI validate options with --config-precedence cli-override 1`] = `
"Invalid printWidth value.
Expected an integer, but received: 0.5"
`;
exports[`CLI validate options with --config-precedence file-override 1`] = `
"Invalid printWidth value.
Expected an integer, but received: 0.5"
`;
exports[`CLI validate options with --config-precedence prefer-file 1`] = `
"Invalid printWidth value.
Expected an integer, but received: 0.5"
`;