diff --git a/changelog_unreleased/api/pr-5813.md b/changelog_unreleased/api/pr-5813.md new file mode 100644 index 000000000..bc9daf48a --- /dev/null +++ b/changelog_unreleased/api/pr-5813.md @@ -0,0 +1 @@ +#### [BREAKING] Fix config overrides pattern matching to include dot files ([#5813](https://github.com/prettier/prettier/pull/5813) by [@chrisblossom](https://github.com/chrisblossom)) diff --git a/tests_integration/__tests__/__snapshots__/config-resolution.js.snap b/tests_integration/__tests__/__snapshots__/config-resolution.js.snap index fd68b478c..526868ace 100644 --- a/tests_integration/__tests__/__snapshots__/config-resolution.js.snap +++ b/tests_integration/__tests__/__snapshots__/config-resolution.js.snap @@ -26,6 +26,9 @@ function f() { console.log( \\"should have no semi\\" ) +console.log( + \\"jest/__best-tests__/.file.js should have semi\\" +); console.log( \\"jest/__best-tests__/file.js should have semi\\" ); @@ -134,6 +137,7 @@ function f() { ) } console.log(\\"should have no semi\\") +console.log(\\"jest/__best-tests__/.file.js should have semi\\"); 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\\"); diff --git a/tests_integration/__tests__/__snapshots__/with-config-precedence.js.snap b/tests_integration/__tests__/__snapshots__/with-config-precedence.js.snap index 17dcd9711..8e3636116 100644 --- a/tests_integration/__tests__/__snapshots__/with-config-precedence.js.snap +++ b/tests_integration/__tests__/__snapshots__/with-config-precedence.js.snap @@ -105,6 +105,9 @@ function f() { console.log( \\"should have no semi\\" ) +console.log( + \\"jest/__best-tests__/.file.js should have semi\\" +); console.log( \\"jest/__best-tests__/file.js should have semi\\" ); @@ -197,6 +200,9 @@ function f() { console.log( \\"should have no semi\\" ) +console.log( + \\"jest/__best-tests__/.file.js should have semi\\" +); console.log( \\"jest/__best-tests__/file.js should have semi\\" ); diff --git a/tests_integration/cli/config/jest/__best-tests__/.file.js b/tests_integration/cli/config/jest/__best-tests__/.file.js new file mode 100644 index 000000000..c2e7ef129 --- /dev/null +++ b/tests_integration/cli/config/jest/__best-tests__/.file.js @@ -0,0 +1 @@ +console.log("jest/__best-tests__/.file.js should have semi");