Skip to content

Commit

Permalink
update test setup
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisShank committed Jan 9, 2024
1 parent 75bfba1 commit 8d6677b
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
## Usage

```ts
import { route, str } from 'routtl';
import { route, string } from 'routtl';

const todoRoute = route`/hello/${['world', str]}`;
const todoRoute = route`/hello/${['world', string]}`;

const url = todoRoute.encode({ world: 'world' });
// ^ '/hello/world'
Expand Down
7 changes: 6 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,17 @@
"import": "./dist/index.js"
}
},
"files": [
"dist/index.js",
"dist/index.d.ts"
],
"scripts": {
"build": "tsc && pnpm test",
"dev": "tsc -w && pnpm test --watch",
"test": "node dist/tests.js"
"test": "node dist/tests.js --test"
},
"devDependencies": {
"@types/node": "^20.10.7",
"typescript": "^5.3.0"
}
}
13 changes: 13 additions & 0 deletions pnpm-lock.yaml

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

6 changes: 6 additions & 0 deletions src/index.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import test, from 'node:test';
import { route, num, string } from './index';

test('works?', () => {
test.
})
1 change: 0 additions & 1 deletion src/tests.ts

This file was deleted.

0 comments on commit 8d6677b

Please sign in to comment.