Add Vitest test framework and CircleCI CI pipeline - #93
Open
circleci-app[bot] wants to merge 1 commit into
Open
Conversation
- Install vitest and jsdom as dev dependencies - Add vitest.config.ts with jsdom environment and @common path alias - Add "test": "vitest run" script to package.json - Write 11 unit tests for isChromeURL, isFirefoxURL, getHostname, and getFaviconURL - Create .circleci/config.yml with npm caching, lint, type-check, and test steps - Fix pre-existing lint error: remove unused `injectExtension` import in background.ts AI-Generated: true
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
isChromeURL,isFirefoxURL(src/common/common.ts),getHostname, andgetFaviconURL(src/content/ui/components/ListItems/utils.ts).circleci/config.ymlcreated with: dependency caching, lint, TypeScript type-check, and test stepsinjectExtensionimport frombackground.ts(its call was already commented out)New files
.circleci/config.ymlvitest.config.ts@commonaliassrc/common/common.test.tssrc/content/ui/components/ListItems/utils.test.tsgetHostname/getFaviconURLTest plan
npm run lint— clean (0 errors)tsc --noEmit— passesnpm test— 2 test files, 11 tests, all passinghttps://app.circleci.com/agents/circleci/977715b4-c847-474d-bc08-01d21c55ef7e/chat/f7f0958f-1476-4196-8398-6e6e90c991bc