# Willyu1007 Mytrader Test Perf K6

> k6 Performance Testing (workflow)

- Skill: `tomevault-io/willyu1007-mytrader-test-perf-k6` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add tomevault-io/willyu1007-mytrader-test-perf-k6`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tomevault-io/willyu1007-mytrader-test-perf-k6/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Productivity
- Author: tomevault-io (https://skillmd.com/u/tomevault-io)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tomevault-io/willyu1007-mytrader-test-perf-k6

---


# k6 Performance Testing (workflow)

## Operating mode (token-efficient)
- Treat this skill as a **router + governor**.
- Do **not** load multiple procedures. Select exactly **one** procedure below and follow it end-to-end.
- Optimize for reproducible performance signals (thresholds + stable environments).

## Routing (pick one procedure)

| Task | Open this procedure | Optional examples |
|---|---|---|
| Bootstrap k6 perf testing in a repo | `reference/procedures/bootstrap.md` | `reference/examples/thresholds.js` |
| Add a new scenario (smoke/load/stress/soak) | `reference/procedures/add-scenario.md` | `reference/examples/smoke.js`, `reference/examples/load.js` |
| Run locally | `reference/procedures/run-local.md` | — |
| Add CI gating (threshold-based) | `reference/procedures/ci-gate.md` | `reference/examples/thresholds.js` |
| Interpret regressions | `reference/procedures/interpret-regressions.md` | — |

## Shared non-negotiables (apply to all procedures)
1) **Versioned scenarios**
   - Store k6 scripts in-repo and review like code.
   - Keep scenarios small and composable.

2) **Explicit thresholds**
   - Every CI-gated scenario must have thresholds (p95/p99 latency, error rate).
   - Thresholds must be justified and documented.

3) **Environment control**
   - Prefer stable staging environments for consistent results.
   - Do not run load/stress tests against production unless explicitly approved.

4) **Artifact contract (for CI + trend analysis)**
   - Standardize under: `artifacts/k6/`
   - Export at least a JSON summary (and optionally JUnit-like output if you convert).

5) **No secrets in repo**
   - Inject tokens via CI secrets / env vars.
   - Never commit API tokens in scripts.

## Minimal inputs you should capture before changing code
- Target endpoint(s) and base URL(s)
- Auth strategy for load tests (token acquisition and rotation strategy)
- Target SLOs / acceptable latency and error rates
- Load model (users, arrival rate, duration)
- Whether tests are PR-gating vs scheduled (nightly)

## Verification
- If you changed **skills**:
  - Prefer host-repo tooling if present:
    - `node .ai/scripts/lint-skills.cjs --strict`
  - Always run the local validator:
    - `node .ai/skills/testing/test-perf-k6/scripts/validate-skill.cjs`

- If you changed **perf scripts**:
  - `k6 version` (or `docker run --rm grafana/k6 version`)
  - `k6 run <script.js>`

## Boundaries
- Do not edit `.codex/skills/` or `.claude/skills/` directly (generated).
- Do not set thresholds so loose that regressions pass unnoticed.
- Do not run high-load tests without coordinating capacity and rate limits.

---
> Converted and distributed by [TomeVault](https://tomevault.io/claim/willyu1007) — claim your Tome and manage your conversions.
<!-- tomevault:4.0:skill_md:2026-04-16 -->

