Skip to content

Commit

Permalink
Add -- to .vscode/settings.json:vitest.commandLine
Browse files Browse the repository at this point in the history
* Add details on Vitest to CREATING.md
  • Loading branch information
iva2k committed Feb 10, 2024
1 parent c194f92 commit 3b81412
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"editor.defaultFormatter": "DotJoshJohnson.xml"
},
"npm.packageManager": "pnpm",
"vitest.commandLine": "pnpm run test:unit",
"vitest.commandLine": "pnpm run test:unit --",
"markdownlint.config": {
"MD033": {
"allowed_elements": ["table", "td", "tr", "thead", "tbody", "img", "a"]
Expand Down
14 changes: 13 additions & 1 deletion CREATING.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,9 @@ pnpm install -D cross-env glob rimraf minimist @types/minimist sass shx vite-plu
pnpm install -D ts-node tsx
```

Add assets copying to svelte.config.js (see source file).
Add assets copying scripts `scripts/assets-copy.ts` and `scripts/assets-clean.ts` to `package.json`.

Add assets copying during dev using 'vite-plugin-static-copy' to svelte.config.js (see source file).

### Lint Error "illegal variable name"

Expand Down Expand Up @@ -240,6 +242,14 @@ Add some scripts:
}
```
The recommended VSCode extension Vitest "zixuanchen.vitest-explorer" provides control of unit tests in VSCode side-panel.
#### Issue with Vitest VSCode extension
As of 2024-0210, extension Vitest "zixuanchen.vitest-explorer" is not showing any of the tests. Of all other vitest extensions in the marketplace, none show the tests in the panel, and the ones that insert shortcuts in the source editor fail to run vitest. So there is no working integration with VSCode (tested on Windows).
TODO: (now) file issue(s) for "zixuanchen.vitest-explorer".
### Playwright Reports
Add few lines to `playwright.config.ts` file so HTML and .json reports are generated:
Expand All @@ -256,6 +266,8 @@ const config: PlaywrightTestConfig = {
...
```
The recommended VSCode extension Microsoft Playwright Test for VSCode "ms-playwright.playwright" provides control of integration tests in VSCode side-panel.
### Organize template components into `src/lib/components`
Move `src/routes/Counter.svelte` to `src/lib/components/counter/` and change paths to match in `src/routes/+page.svelte` file where it is used.
Expand Down

0 comments on commit 3b81412

Please sign in to comment.