Skip to content

Commit a73d460

Browse files
committed
add note to README about tests
1 parent 810f187 commit a73d460

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

README.md

+25
Original file line numberDiff line numberDiff line change
@@ -143,3 +143,28 @@ downloads the model from huggingface and queries it locally
143143
## Discord Bot
144144

145145
For help with setting up your Discord Bot, check out here: https://discordjs.guide/preparations/setting-up-a-bot-application.html
146+
147+
# Development
148+
149+
## Testing
150+
151+
To run the test suite:
152+
153+
```bash
154+
pnpm test # Run tests once
155+
pnpm test:watch # Run tests in watch mode
156+
```
157+
158+
For database-specific tests:
159+
```bash
160+
pnpm test:sqlite # Run tests with SQLite
161+
pnpm test:sqljs # Run tests with SQL.js
162+
```
163+
164+
Tests are written using Jest and can be found in `src/**/*.test.ts` files. The test environment is configured to:
165+
- Load environment variables from `.env.test`
166+
- Use a 2-minute timeout for long-running tests
167+
- Support ESM modules
168+
- Run tests in sequence (--runInBand)
169+
170+
To create new tests, add a `.test.ts` file adjacent to the code you're testing.

0 commit comments

Comments
 (0)