feat: support sorting package.json #10
Annotations
5 errors and 1 warning
tests/index.spec.ts > test config > option is undefined:
tests/index.spec.ts#L6
AssertionError: expected { printWidth: 120, …(5) } to strictly equal { printWidth: 120, …(4) }
- Expected
+ Received
Object {
"importOrder": Array [
"<BUILTIN_MODULES>",
"^vue$",
"^react$",
"<THIRD_PARTY_MODULES>",
"^@/(.*)$",
"^~/(.*)$",
"^[.]",
],
+ "overrides": Array [
+ Object {
+ "files": "**/package.json",
+ "options": Object {
+ "packageSortOrder": Array [],
+ },
+ },
+ ],
"plugins": Array [
"@ianvs/prettier-plugin-sort-imports",
"prettier-plugin-tailwindcss",
+ "prettier-plugin-packagejson",
],
"printWidth": 120,
"semi": false,
"singleQuote": true,
}
❯ tests/index.spec.ts:6:28
|
tests/index.spec.ts > test config > sortImports is false:
tests/index.spec.ts#L16
AssertionError: expected { printWidth: 120, …(5) } to strictly equal { printWidth: 120, …(4) }
- Expected
+ Received
Object {
"importOrder": undefined,
+ "overrides": Array [
+ Object {
+ "files": "**/package.json",
+ "options": Object {
+ "packageSortOrder": Array [],
+ },
+ },
+ ],
"plugins": Array [
"prettier-plugin-tailwindcss",
+ "prettier-plugin-packagejson",
],
"printWidth": 120,
"semi": false,
"singleQuote": true,
}
❯ tests/index.spec.ts:16:50
|
tests/index.spec.ts > test config > sortImports is false:
tests/index.spec.ts#L26
AssertionError: expected { printWidth: 120, …(5) } to strictly equal { printWidth: 120, …(4) }
- Expected
+ Received
Object {
"importOrder": Array [
"<BUILTIN_MODULES>",
"^vue$",
"^react$",
"<THIRD_PARTY_MODULES>",
"^@/(.*)$",
"^~/(.*)$",
"^[.]",
],
+ "overrides": Array [
+ Object {
+ "files": "**/package.json",
+ "options": Object {
+ "packageSortOrder": Array [],
+ },
+ },
+ ],
"plugins": Array [
"@ianvs/prettier-plugin-sort-imports",
+ "prettier-plugin-packagejson",
],
"printWidth": 120,
"semi": false,
"singleQuote": true,
}
❯ tests/index.spec.ts:26:54
|
tests/index.spec.ts > test config > custom config:
tests/index.spec.ts#L38
AssertionError: expected { printWidth: 120, …(6) } to strictly equal { printWidth: 120, …(5) }
- Expected
+ Received
Object {
"importOrder": Array [
"<BUILTIN_MODULES>",
"^vue$",
"^react$",
"<THIRD_PARTY_MODULES>",
"^@/(.*)$",
"^~/(.*)$",
"^[.]",
],
+ "overrides": Array [
+ Object {
+ "files": "**/package.json",
+ "options": Object {
+ "packageSortOrder": Array [],
+ },
+ },
+ ],
"plugins": Array [
"@ianvs/prettier-plugin-sort-imports",
"prettier-plugin-tailwindcss",
+ "prettier-plugin-packagejson",
"prettier-plugin-test",
],
"printWidth": 120,
"semi": true,
"singleQuote": true,
"vueIndentScriptAndStyle": true,
}
❯ tests/index.spec.ts:38:7
|
test
Process completed with exit code 1.
|
test
ubuntu-latest pipelines will use ubuntu-24.04 soon. For more details, see https://github.com/actions/runner-images/issues/10636
|