-
Notifications
You must be signed in to change notification settings - Fork 663
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add vitest to GitHub actions #9162
Conversation
Failing tests are expected per #9083 (comment). Successful run can be seen in https://github.com/pantheon-systems/documentation/actions/runs/10307574827/job/28533128469?pr=9161 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @jazzsequence. I made the filename more specific.
I left it open ended in case we wanted to use it for other types of tests, but since we're running on specific paths, that's probably fine. |
* mdx and import ordering * Update index.js * whitespace fixes * BackstopJS init for local VRT (#8989) * removing potentially unneeded component * Revert "removing potentially unneeded component" This reverts commit d95bca8. * removing releaseHeadlines from MdxWrapper * adding more pages to backstop * adding npx to instructions * mdx customshortcodes * Revert "BackstopJS init for local VRT (#8989)" This reverts commit 5b9f380. * starting on a new sidebar * getting sidebar somewhat functional * more sidebar nav playing * Certification multilevel nav * Getting certification working with multilevel menu * more sidebar experimenting * sidebar nav graphql-ing * adding guides to omni nav * adding subtitles * adding stuff * more nav * link nesting * more link mucking * still working * still working * removing commented out code * cleanup * starting on omni component * trying function in separate file * functioning again * submenus * wrangling the guides * getting decoupled guides * more decouple guiding * more simplification * splitting up * segmenting out guide function * delete unused files * guide! * whitespace * more re-arranging * no errors * remove unused stuff * no errors with query coming from outside index.js * more tweaks * adding OmniSidebarNavWithFallback.js * fallback is working in guide * whitespace * using fallback * more cleanup * getting rid of separate OmniSidebarNavWithFallback * more cleanup * link fix * screenshot testing nav * update prettier * running prettier * switching prettier standard based on internal discussion * adding eslint * adding eslint * Revert "adding eslint" This reverts commit f84fc28. * Revert "adding eslint" This reverts commit 7705f80. * Revert "running prettier" This reverts commit e4f05fb. * small prettier formatting * formatting * manual spacing * more manual * manual formatting * prettier with manual fix * prettier fixes * simplify regex * prettier comment * Revert "prettier comment" This reverts commit 7f95a83. * going back to work regex * I do not even need the regex * adding vitest * adding unit tests samples * moving helper functions to their own file * more testing * query in its own file * more unit testing * one more unit test * fix * removing helper functions that were too small * more moving helper functions * moving deck chairs * removing a too small function. And removing sample unit test * deleting separate sidebarNav component * moving test fixture * simplyfing a function * simplify data structures * running prettier * checking for search js before adding it * cleanup * adding some doc blocks and minor refactor * docs and cleanup * more comments * more cleanup * more comments more tests * adding all the front-end sites guides * removing extra nav alert in the middle of decouple overview pages * running prettier * going back to old prettier config files. Redo this change under #9082 * starting to add a styling file for omnisidebarnav * starting on styling * getting external link indicator working * remove extra arrow in link * removing console.log * Add vitest to GitHub actions (#9162) * Add vitest to GHA * Make a clean install * switching from jsx to React.createElement() * Update and rename test.yml to vitest.yml --------- Co-authored-by: Steve Persch <steve.persch@pantheon.io> Co-authored-by: Steve Persch <stevector@users.noreply.github.com> * moving icon to back and setting to small * testing readme * fixing link * copy fix * changing addsearch back * addsearch back * adding vite.config.ts * Updating import order * update tests readme * Apply Prettier formatting * removing comment * vitest fix, fingers crossed * adding rollup * package merges * re-adding vitest stuff --------- Co-authored-by: Rachel Whitton <rachel@pantheon.io> Co-authored-by: Chris Reynolds <chris.reynolds@pantheon.io> Co-authored-by: Pantheon Bot <bot@getpantheon.com>
Fixes #9083
Replaces #9161
Summary
Adds a GitHub actions workflow to run
npx vitest src/components
on PRs that change files insrc/
(can be altered to limit that scope tosrc/components/
or if the workflow itself is updated.Also allows for manual triggering (
workflow_dispatch
) in the Actions tab.