Skip to content

Commit

Permalink
test: fix jest setup
Browse files Browse the repository at this point in the history
  • Loading branch information
christianmat committed Oct 24, 2024
1 parent 36b412b commit f264482
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
11 changes: 11 additions & 0 deletions packages/trench-js/jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
export default {
preset: 'ts-jest',
testEnvironment: 'node',
globals: {
'ts-jest': {
tsconfig: 'tsconfig.json',
},
},
moduleFileExtensions: ['ts', 'js'],
testMatch: ['**/test/**/*.ts'],
};
9 changes: 2 additions & 7 deletions packages/trench-js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,13 @@
"description": "Trench JS client for browser and Node.js",
"main": "lib/index.js",
"types": "lib/index.d.ts",
"type": "module",
"files": [
"lib"
],
"scripts": {
"build": "tsc",
"format": "prettier --write \"src/**/*.ts\"",
"lint": "tslint -p tsconfig.json -c tslint.json --fix",
"prepare": "npm run build",
"prepublishOnly": "npm run lint",
"preversion": "npm run lint",
"version": "npm run format && git add -A src",
"postversion": "git push && git push --tags"
"test": "jest"
},
"repository": {
"type": "git",
Expand Down

0 comments on commit f264482

Please sign in to comment.