vbinupx/upx-cli/testing
Claude Code and agent skill by vbinupx/upx-cli
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
Testing guide using Vitest. Use when writing tests (.test.ts, .test.tsx), fixing failing tests, improving test coverage, or debugging test issues. Triggers on test creation, test debugging, mock setup, or test-related questions.
Install
npx vskill@latest install vbinupx/upx-cli/testingSKILL.md
The same SKILL.md was published earlier as koopos/hermes/testing.
LobeChat Testing Guide
Quick Reference
Commands:
Never run bun run test - it runs all 3000+ tests (~10 minutes).
Test Categories
| Category | Location | Config | |
|---|---|---|---|
| Webapp | src/**/*.test.ts(x) | vitest.config.ts | |
| Packages | packages/*/**/*.test.ts | packages/*/vitest.config.ts | |
| Desktop | apps/desktop/**/*.test.ts | apps/desktop/vitest.config.ts |
Core Principles
- Prefer `vi.spyOn` over `vi.mock` - More targeted, easier to maintain
- Tests must pass type check - Run
bun run type-checkafter writing tests - After 1-2 failed fix attempts, stop and ask for help
- Test behavior, not implementation details
Basic Test Structure
Mock Patterns
Detailed Guides
See references/ for specific testing scenarios:
- Database Model testing:
references/db-model-test.md - Electron IPC testing:
references/electron-ipc-test.md - Zustand Store Action testing:
references/zustand-store-action-test.md - Agent Runtime E2E testing:
references/agent-runtime-e2e.md - Desktop Controller testing:
references/desktop-controller-test.md
Common Issues
- Module pollution: Use
vi.resetModules()when tests fail mysteriously - Mock not working: Check setup position and use
vi.clearAllMocks()in beforeEach - Test data pollution: Clean database state in beforeEach/afterEach
- Async issues: Wrap state changes in
act()for React hooks
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/testing/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/vbinupx/upx-cli/testing)