|
| 1 | +# vitest-ecosystem-ci |
| 2 | + |
| 3 | +This repository is used to run tests for vitest ecosystem projects |
| 4 | + |
| 5 | +## via github workflow |
| 6 | + |
| 7 | +### scheduled |
| 8 | + |
| 9 | +Workflows are sheduled to run automatically every Monday, Wednesday and Friday |
| 10 | + |
| 11 | +### manually |
| 12 | + |
| 13 | +- open [workflow](../../actions/workflows/ecosystem-ci-selected.yml) |
| 14 | +- click 'Run workflow' button on top right of the list |
| 15 | +- select suite to run in dropdown |
| 16 | +- start workflow |
| 17 | + |
| 18 | +## via shell script |
| 19 | + |
| 20 | +- clone this repo |
| 21 | +- run `pnpm i` |
| 22 | +- run `pnpm test` to run all suites |
| 23 | +- or `pnpm test <suitename>` to select a suite |
| 24 | +- or `tsx ecosystem-ci.ts` |
| 25 | + |
| 26 | +You can pass `--tag v2.8.0-beta.1`, `--branch somebranch` or `--commit abcd1234` option to select a specific vitest version to build. |
| 27 | +If you pass `--release 2.7.13`, vitest build will be skipped and vitest is fetched from the registry instead |
| 28 | + |
| 29 | +The repositories are checked out into `workspace` subdirectory as shallow clones |
| 30 | + |
| 31 | +# how to add a new integration test |
| 32 | + |
| 33 | +- check out the existing [tests](./tests) and add one yourself. Thanks to some utilities it is really easy |
| 34 | +- once you are confidente the suite works, add it to the lists of suites in the [workflows](../../actions/) |
| 35 | + |
| 36 | +> the current utilities focus on pnpm based projects. Consider switching to pnpm or contribute utilities for other pms |
| 37 | +
|
| 38 | +# reporting results |
| 39 | + |
| 40 | +## Discord |
| 41 | + |
| 42 | +Results are posted automatically to `#ecosystem-ci` on [vitest discord](https://chat.vitest.dev/) |
| 43 | + |
| 44 | +### on your own server |
| 45 | + |
| 46 | +- Go to `Server settings > Integrations > Webhooks` and click `New Webhook` |
| 47 | +- Give it a name, icon and a channel to post to |
| 48 | +- copy the webhook url |
| 49 | +- get in touch with admins of this repo so they can add the webhook |
| 50 | + |
| 51 | +#### how to add a discord webhook here |
| 52 | + |
| 53 | +- Go to `<github repo>/settings/secrets/actions` and click on `New repository secret` |
| 54 | +- set `Name` as `DISCORD_WEBHOOK_URL` |
| 55 | +- paste the discord webhook url you copied from above into `Value` |
| 56 | +- Click `Add secret` |
0 commit comments