Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
andyexeter committed Nov 21, 2023
1 parent f11e402 commit 852d722
Show file tree
Hide file tree
Showing 5 changed files with 582 additions and 4 deletions.
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
dist/
23 changes: 23 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"endOfLine": "lf",
"trailingComma": "all",
"tabWidth": 2,
"semi": true,
"singleQuote": true,
"printWidth": 100,
"overrides": [
{
"files": "*.spec.ts",
"options": {
"printWidth": 100
}
},
{
"files": "*.liquid",
"options": {
"singleQuote": false,
"printWidth": 80
}
}
]
}
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,14 @@
"nyc": "^15.1.0",
"prettier2": "npm:prettier@^2.6.1",
"prettier3": "npm:prettier@^3.0.0",
"prettier": "^3.1.0",
"pretty-quick": "^3.1.3",
"source-map-support": "^0.5.21",
"ts-node": "^10.4.0",
"tsc-alias": "^1.6.7",
"tsconfig-paths": "^3.14.1",
"typescript": "^4.5.2",
"vitest": "^0.34.6",
"webpack": "^5.70.0",
"webpack-cli": "^4.9.2"
},
Expand Down
4 changes: 2 additions & 2 deletions test/test-setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ const path = require('path');
const prettierMajor = process.env.PRETTIER_MAJOR;
const prettierPath =
process.env.PRETTIER_MAJOR === '3'
? path.join(__dirname, '..', '..', '..', 'node_modules', 'prettier3')
: path.join(__dirname, '..', '..', '..', 'node_modules', 'prettier2');
? path.join(__dirname, '..', 'node_modules', 'prettier3')
: path.join(__dirname, '..', 'node_modules', 'prettier2');

export function setup() {
moduleAlias.addAlias('prettier', prettierPath);
Expand Down
Loading

0 comments on commit 852d722

Please sign in to comment.