Skip to content

Commit

Permalink
test: move tests to typescript
Browse files Browse the repository at this point in the history
Moves the tests to typescript and cleans up some things which the
compiler picked up.
  • Loading branch information
43081j committed Jan 19, 2025
1 parent f0dd049 commit 4841cd3
Show file tree
Hide file tree
Showing 7 changed files with 180 additions and 146 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@
/node_modules/
/test-fixtures/
/*.d.ts
/*.d.mts
/*.map
/index.js
/handler.js
/esm
/esm
/*.test.js
/*.test.mjs
54 changes: 51 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 6 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"index.d.ts",
"handler.js",
"handler.d.ts",
"esm"
"esm",
"!**/*.test.*"
],
"main": "./index.js",
"module": "./esm/index.js",
Expand All @@ -29,7 +30,10 @@
},
"devDependencies": {
"@paulmillr/jsbt": "0.2.1",
"@types/chai": "^5.0.1",
"@types/node": "20.14.8",
"@types/sinon": "^17.0.3",
"@types/sinon-chai": "^4.0.0",
"chai": "4.3.4",
"micro-should": "0.5.0",
"prettier": "3.1.1",
Expand All @@ -54,7 +58,7 @@
"build": "tsc && tsc -p tsconfig.esm.json",
"lint": "prettier --check src",
"format": "prettier --write src",
"test": "node test.mjs"
"test": "node index.test.mjs"
},
"keywords": [
"fs",
Expand Down
Loading

0 comments on commit 4841cd3

Please sign in to comment.