Skip to content

Commit 6136185

Browse files
fixup!: update CONTRIBUTING.md with test info
1 parent 40f5b5f commit 6136185

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

CONTRIBUTING.md

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,22 @@ A recipe generally has a few things:
55
* A `README.md` explaining its purpose and use (including any options, and required and optional
66
files).
77
* Tests via node's test runner (min coverage: 80%)
8-
* unit tests (file extension: `.spec.mjs` or `.spec.mts`)
9-
* end-to-end test(s) for accepted use-cases (file extension: `.e2e.mjs` or `.e2e.mts`)
8+
* unit tests ; there must be a `"test:unit"` command within it package.json's like:
9+
```json
10+
{
11+
"scripts": {
12+
"test:unit": "node --test './src/**/*.spec.ts"
13+
}
14+
}
15+
```
16+
* end-to-end test(s) for accepted use-cases; there must be a `"test:e2e"` command within it package.json's like:
17+
```json
18+
{
19+
"scripts": {
20+
"test:e2e": "node --test './src/**/*.e2e.ts"
21+
}
22+
}
23+
```
1024
* Code comments (js docs, etc)
1125
* Types (either via typescript or jsdoc)
1226

0 commit comments

Comments
 (0)