本文へ移動
cccskills
無料GitHub で公開

testing-and-ci

Testing conventions, CI pipeline rules, and smoke test coverage for SkillHub. Ensures agents write tests correctly and understand the CI gate requirements.

インストール方法を見る

含まれるファイル(1)

  • SKILL.md4.2 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Testing and CI Skill

Trigger

Use this skill when:

  • Adding or modifying backend tests
  • Adding or modifying frontend tests
  • Changing CI/CD workflows
  • Adding smoke tests or E2E tests

Rules

Backend Testing

Tests live alongside source in each module's src/test/java/:

  • server/skillhub-app/src/test/java/ — Controller integration tests, service tests
  • server/skillhub-domain/src/test/java/ — Domain service unit tests
  • server/skillhub-auth/src/test/java/ — Auth flow tests

Tools: JUnit 5 + Mockito + AssertJ + Spring Boot test slices (@WebMvcTest, @DataJpaTest)

Build commands:

make test-backend-app   # skillhub-app + dependencies (includes -am)
make test-backend       # all backend modules

Never run ./mvnw -pl skillhub-app clean test directly under server/. skillhub-app depends on sibling modules, and a standalone clean build can fall back to stale artifacts from the local Maven repository, surfacing misleading cannot find symbol and signature-mismatch errors. Use -am, or the Makefile targets above.

Test naming conventions:

  • Controller tests: {ControllerName}Test.java (e.g., SkillControllerTest.java)
  • Service tests: {ServiceName}Test.java
  • Integration tests: {FlowName}IntegrationTest.java
  • Security tests: {ControllerName}SecurityTest.java

Frontend Testing

Tools: Vitest (unit), Playwright (E2E)

make test-frontend            # Vitest unit tests (pnpm run test)
make test-e2e-frontend        # Playwright E2E tests
make test-e2e-smoke-frontend  # Playwright smoke tests (subset)

E2E tests live in web/e2e/.

Smoke Tests

Smoke tests validate end-to-end operator workflows against a running backend:

ScriptPurpose
scripts/smoke-test.shBasic API health, auth, label CRUD
scripts/namespace-smoke-test.shNamespace creation, membership, publishing
scripts/governance-smoke-test.shGovernance and moderation flows
scripts/promotion-smoke-test.shSkill promotion between scopes

When operator-facing workflows change, update the corresponding smoke test.

CI Pipeline

GitHub Actions workflows in .github/workflows/:

WorkflowTriggerPurpose
pr-tests.ymlPRBackend + frontend unit tests
pr-e2e.ymlPRE2E smoke tests against staging
pr-batch-test-deploy.ymlworkflow_dispatchBatch test and deploy
publish-images.ymlrelease published / workflow_dispatchBuild and publish Docker images to GHCR
deploy-docs.ymlpush to docsDeploy documentation site
issue-triage.ymlissuesAuto-triage incoming issues
issue-backlog-rescore.ymlcron (every 6h)Rescore backlog issues
release-notes.ymlworkflow_dispatchGenerate release notes
deepwiki.ymlrelease publishedUpdate DeepWiki documentation
claim-issue-reward.ymlissue_commentAuto-claim issue rewards
statistic-member-reward.ymlcron/scheduleCalculate member rewards

All workflows live in .github/workflows/. Deno scripts for triage, release notes, and rewards live in .github/scripts/.

Staging

Before opening a PR, validate with staging:

make staging          # Build backend Docker image + frontend static + smoke test
make staging-down     # Tear down
SERVICE=web make staging-logs  # View Nginx logs

Staging validates the containerized deployment path:

  • Backend: built as Docker image from local source (Dockerfile.dev)
  • Frontend: built as static files (pnpm build), served by Nginx
  • Dependencies: same Postgres/Redis/MinIO as local dev

If staging passes, the environment stays running at:

  • Web UI: http://localhost
  • Backend API: http://localhost:8080

Pre-PR Testing Checklist

  • make test-backend-app passes
  • make typecheck-web passes
  • make lint-web passes (if frontend changed)
  • make staging passes (full regression)
  • If API changed: make generate-api run and generated file committed
  • New behavior has corresponding tests

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Evaluate factual claims in AI-generated text and teach a lightweight verification habit. Use when a learner wants to fact-check an AI answer, identify uncertainty, choose appropriate independent sources, or practise critical AI literacy.

日本語の概要は準備中です。原文の説明を表示しています。

iflytek/skillhub5,1712026年10月10日 更新

API design conventions, namespace coordinate system, RBAC roles, ClawHub compatibility layer, OpenAPI contract sync rules, and CSRF/session handling.

日本語の概要は準備中です。原文の説明を表示しています。

iflytek/skillhub5,1712026年10月10日 更新

Rules for the SkillHub backend Maven multi-module clean architecture. Ensures agents place new code in the correct module and respect dependency direction.

日本語の概要は準備中です。原文の説明を表示しています。

iflytek/skillhub5,1712026年10月10日 更新

Code style, logging, and testing conventions for SkillHub backend (Java) and frontend (TypeScript). Use when writing or reviewing code.

日本語の概要は準備中です。原文の説明を表示しています。

iflytek/skillhub5,1712026年10月10日 更新

Parse and understand an HTTP(S) URL or an authorized local document, audio, or video source through Cue Omni Reader when the Agent has the official Omni MCP tools.

日本語の概要は準備中です。原文の説明を表示しています。

iflytek/skillhub5,1712026年10月10日 更新

Generate concise daily standups, reflection prompts, and weekly retrospectives for individuals or teams. Use for planning a day, surfacing blockers, reviewing user-provided entries, or drafting a check-in without assuming prior history.

日本語の概要は準備中です。原文の説明を表示しています。

iflytek/skillhub5,1712026年10月10日 更新

iflytek のスキルをすべて見る

このスキルの問題を報告する