Llmops-demo-ts write-tests
Write unit tests, integration tests, or E2E tests for code. Use after implementing a feature or when test coverage is needed.
install
source · Clone the upstream repo
git clone https://github.com/yu-iskw/llmops-demo-ts
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/yu-iskw/llmops-demo-ts "$T" && mkdir -p ~/.claude/skills && cp -r "$T/.claude/skills/write-tests" ~/.claude/skills/yu-iskw-llmops-demo-ts-write-tests && rm -rf "$T"
manifest:
.claude/skills/write-tests/SKILL.mdsource content
Write Tests
Write tests for the following:
$ARGUMENTS
Testing Strategy
- Identify what to test: Read the source code to understand behavior
- Choose test type:
- Unit tests (Jest): Individual functions/classes —
alongside source*.test.ts - E2E tests (Playwright): Full user flows —
packages/frontend/src/tests/ - Evaluation (LangSmith): AI agent quality —
directorieseval/langsmith/
- Unit tests (Jest): Individual functions/classes —
- Write tests following project patterns:
Jest Test Template
import { describe, it, expect, jest, beforeEach } from "@jest/globals"; describe("FunctionName", () => { it("should handle normal input", () => { // Arrange → Act → Assert }); it("should handle edge cases", () => { // Empty, null, boundary values }); it("should handle errors", () => { // Error paths and exceptions }); });
- Run tests to verify they pass:
— Agent testspnpm test:agents
— Backend testspnpm test:backend
— Common package testspnpm test:common
— E2E testspnpm test:frontend
Test Coverage Goals
- Utility functions: 90%+
- Agent nodes: 80%+
- API endpoints: 80%+
- Vue components: 70%+