Skip to content

Commit 0a21cb5

Browse files
Michael-ObeleCopilot
andcommitted
feat: add CONTRIBUTING.md and update README with contribution guidelines; modify Vite config for headless browser testing
Co-authored-by: Copilot <copilot@github.com>
1 parent 516bc45 commit 0a21cb5

3 files changed

Lines changed: 33 additions & 2 deletions

File tree

CONTRIBUTING.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Contributing
2+
3+
Thanks for helping improve `sveltekit-openapi-generator`.
4+
5+
## Before You Commit
6+
7+
Run the test suite before committing changes:
8+
9+
```bash
10+
bunx vitest run
11+
```
12+
13+
If your change touches package output or published files, also run:
14+
15+
```bash
16+
npm run package
17+
```
18+
19+
## Recommended Workflow
20+
21+
1. Make your change.
22+
2. Run `bunx vitest run`.
23+
3. Fix any failing tests.
24+
4. Run `npm run package` if the change affects built output.
25+
5. Commit once both checks are green.
26+
27+
## Good PRs
28+
29+
Keep changes focused, include tests for behavioral changes, and call out any generated artifacts that changed as a result of the update.

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -565,7 +565,9 @@ declare module 'virtual:openapi-spec' {
565565
566566
## 🤝 Contributing
567567
568-
Contributions are welcome! Please feel free to submit a Pull Request.
568+
Contributions are welcome. Before committing, run `bunx vitest run` to make sure the unit and browser suites still pass.
569+
570+
See [CONTRIBUTING.md](CONTRIBUTING.md) for the full workflow and checklist.
569571
570572
<a name="license"></a>
571573

vite.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ export default defineConfig({
4242
browser: {
4343
enabled: true,
4444
provider: 'playwright',
45-
instances: [{ browser: 'chromium' }]
45+
instances: [{ browser: 'chromium', headless: true }]
4646
},
4747
include: ['src/**/*.svelte.{test,spec}.{js,ts}'],
4848
exclude: ['src/lib/server/**'],

0 commit comments

Comments
 (0)