Skip to content

Commit

Permalink
chore: repro
Browse files Browse the repository at this point in the history
  • Loading branch information
hi-ogawa committed Jan 8, 2025
1 parent 59e41a2 commit 236c5ca
Show file tree
Hide file tree
Showing 6 changed files with 40 additions and 0 deletions.
3 changes: 3 additions & 0 deletions examples/repro/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```sh
VITE_NODE_DEBUG_DUMP=1 pnpm -C examples/repro test -- --coverage
```
15 changes: 15 additions & 0 deletions examples/repro/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "@vitest/example-repro",
"type": "module",
"private": true,
"license": "MIT",
"scripts": {
"test": "vitest"
},
"devDependencies": {
"vitest": "latest"
},
"stackblitz": {
"startCommand": "npm run test:ui"
}
}
6 changes: 6 additions & 0 deletions examples/repro/src/basic.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { expect, test } from 'vitest'
import { squared } from './basic'

test('repro', () => {
expect(squared(2)).toBe(4)
})
1 change: 1 addition & 0 deletions examples/repro/src/basic.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export const squared = (n: number) => n * n
9 changes: 9 additions & 0 deletions examples/repro/vite.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { defineConfig } from 'vitest/config'

export default defineConfig({
test: {
coverage: {
reporter: ['text', 'text-summary', 'html', 'clover', 'json'],
},
},
})
6 changes: 6 additions & 0 deletions pnpm-lock.yaml

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

0 comments on commit 236c5ca

Please sign in to comment.