Skip to content

Commit c420cd7

Browse files
committed
test: add type-test for capture groups
1 parent e106458 commit c420cd7

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

.github/workflows/ci.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
run: pnpm install --frozen-lockfile
2525

2626
- name: 🔠 Lint project
27-
run: pnpm run lint
27+
run: pnpm lint
2828

2929
test:
3030
runs-on: ubuntu-latest
@@ -41,10 +41,13 @@ jobs:
4141
run: pnpm install --frozen-lockfile
4242

4343
- name: 🛠 Build project
44-
run: pnpm run build
44+
run: pnpm build
45+
46+
- name: 💪 Test types
47+
run: pnpm test:types
4548

4649
- name: 🧪 Test project
47-
run: pnpm run test --coverage
50+
run: pnpm test --coverage
4851

4952
- name: 🟩 Coverage
5053
uses: codecov/codecov-action@v3

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
"prepublishOnly": "pnpm lint && pnpm test && pinst --disable",
3131
"release": "release-it",
3232
"test": "vitest run",
33+
"test:types": "tsc --noEmit",
3334
"postinstall": "husky install",
3435
"postpublish": "pinst --enable"
3536
},

tsconfig.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"module": "ESNext",
55
"moduleResolution": "Node",
66
"esModuleInterop": true,
7+
"skipLibCheck": true,
78
"paths": {
89
"magic-regexp/transform": ["./src/transform"],
910
"magic-regexp": ["./src/index"]

vite.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { fileURLToPath } from 'url'
1+
import { fileURLToPath } from 'node:url'
22
import { defineConfig } from 'vite'
33

44
export default defineConfig({

0 commit comments

Comments
 (0)