@bytebase/dbhub 0.4.6 → 0.4.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -338,6 +338,24 @@ The demo mode uses an in-memory SQLite database loaded with the [sample employee
|
|
|
338
338
|
pnpm start --transport stdio --dsn "postgres://user:password@localhost:5432/dbname?sslmode=disable"
|
|
339
339
|
```
|
|
340
340
|
|
|
341
|
+
### Testing
|
|
342
|
+
|
|
343
|
+
The project uses Vitest for testing:
|
|
344
|
+
|
|
345
|
+
- Run tests: `pnpm test`
|
|
346
|
+
- Run tests in watch mode: `pnpm test:watch`
|
|
347
|
+
|
|
348
|
+
#### Pre-commit Hooks (for Developers)
|
|
349
|
+
|
|
350
|
+
The project includes pre-commit hooks to run tests automatically before each commit:
|
|
351
|
+
|
|
352
|
+
1. After cloning the repository, set up the pre-commit hooks:
|
|
353
|
+
```bash
|
|
354
|
+
./scripts/setup-husky.sh
|
|
355
|
+
```
|
|
356
|
+
|
|
357
|
+
2. This ensures the test suite runs automatically whenever you create a commit, preventing commits that would break tests.
|
|
358
|
+
|
|
341
359
|
### Debug with [MCP Inspector](https://github.com/modelcontextprotocol/inspector)
|
|
342
360
|
|
|
343
361
|
#### stdio
|