skills/.trash/skillshare/.skillshare/skills/cli-e2e-test/SKILL.md
Run isolated E2E tests in devcontainer from ai_docs/tests runbooks. Use this skill whenever the user asks to: run an E2E test, execute a test runbook, validate a feature end-to-end, create a new runbook, or test CLI behavior in isolation. If you need to run a multi-step CLI validation sequence (init → install → sync → verify), this is the skill — it handles ssenv isolation, flag verification, and structured reporting. Prefer this over ad-hoc docker exec sequences for any test that follows a runbook or needs reproducible isolation.
npx skillsauth add aaaaqwq/agi-super-team skillshare-cli-e2e-testInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Run isolated E2E tests in devcontainer. $ARGUMENTS specifies runbook name or "new".
Confirm devcontainer is running and get container ID:
CONTAINER=$(docker compose -f .devcontainer/docker-compose.yml ps -q skillshare-devcontainer)
docker compose -f .devcontainer/docker-compose.yml up -dCONTAINER is set for all subsequent docker exec calls.Confirm Linux binary is available:
docker exec $CONTAINER bash -c \
'/workspace/.devcontainer/ensure-skillshare-linux-binary.sh && ss version'
*_runbook.md files under ai_docs/tests/ to list available runbooksgit diff --name-only HEAD~3
Prompt user (via AskUserQuestion):
Read the selected runbook .md file
Create isolated environment with auto-initialization:
ENV_NAME="e2e-$(date +%Y%m%d-%H%M%S)"
# Use --init to automatically run 'ss init -g' with all targets
docker exec $CONTAINER ssenv create "$ENV_NAME" --init
Execute each step from runbook:
# Use SKILLSHARE_DEV_ALLOW_WORKSPACE_PROJECT=1 to prevent redirection to demo-project
docker exec $CONTAINER env SKILLSHARE_DEV_ALLOW_WORKSPACE_PROJECT=1 \
ssenv enter "$ENV_NAME" -- <command>
After each step, verify conditions in the Expected block
--json + jq for assertions — structured output is more reliable than grep on human-readable text. See the JSON Reference below for which commands support --json.Mark each step PASS / FAIL
git diff HEAD~3 to find changed files in cmd/skillshare/ or internal/ss <command> <flag> in the runbook:
cmd/skillshare/<command>.go for the exact flag string (e.g. "--force")ss <command> --help inside container if neededuninstall --yes → wrong, use --force / -finit --target <name> → wrong, init has no --target flaginit -p has a completely separate flag set from global init — only supports --targets, --discover, --select, --mode, --dry-run. Global-only flags like --no-copy, --no-skill, --no-git, --all-targets, --force do NOT exist in project modeprompt-injection-0, prompt-injection-1), NOT pattern name (e.g. prompt-injection). Rule IDs are in internal/audit/rules.yamlai_docs/tests/<slug>_runbook.md, following existing conventions:
--json + jq for assertions wherever possible — avoids brittle text matchingAsk user before cleanup (via AskUserQuestion):
ssenv delete)If user chose Option A:
docker exec $CONTAINER ssenv delete "$ENV_NAME" --force
Output summary:
── E2E Test Report ──
Runbook: {runbook name}
Env: {ENV_NAME}
Duration: {time}
Step 1: {description} PASS
Step 2: {description} PASS
Step 3: {description} FAIL ← {error detail}
...
Result: {N}/{total} passed
If any FAIL → distinguish between runbook bug vs real bug:
Retrospective — ask user (via AskUserQuestion):
Did you encounter any friction during this test run that the skill or runbook could handle better?
Improvement targets:
Before executing a newly generated runbook, verify:
ss <cmd> --flag was grep-verified against source--init interaction — if runbook has ss init, account for ssenv create --init already initializing (add --force to re-init, or skip init step)uninstall uses --force (not --yes); init re-run needs no flag (just fails gracefully)registry.yaml, NOT config.yaml; config.yaml should never contain skills:registry.yaml is only created after first install/reconcile, not on ss init.skillshare/ not ~/.config/skillshare/init -p only supports --targets, --discover, --select, --mode, --dry-run; global-only flags (--no-copy, --no-skill, --no-git, --all-targets, --force) are not availableaudit-rules.yaml use rule IDs (e.g. prompt-injection-0), not pattern names (e.g. prompt-injection). Verify IDs against internal/audit/rules.yaml--json for assertions — if the command supports --json, use it with jq instead of grepping human-readable output. Text output changes between versions; JSON structure is stabledocker exec, never run CLI on hostssenv for HOME isolation — don't pollute container default HOMEss = skillshare — same binary in runbooks~ = ssenv-isolated HOME — ssenv enter auto-sets HOME--init — simplify setup by using ssenv create <name> --init--init already runs init — the env is pre-initialized; runbook steps calling ss init again will fail unless the step explicitly resets state first| Command | Purpose |
|---------|---------|
| sshelp | Show shortcuts and usage |
| ssls | List isolated environments |
| ssnew <name> | Create + enter isolated shell (interactive) |
| ssuse <name> | Enter existing isolated shell (interactive) |
| ssback | Leave isolated context |
| ssenv enter <name> -- <cmd> | Run single command in isolation (automation) |
ssnew <env> then exit when donessenv enter <env> -- <command> one-linersWhen running Go tests inside devcontainer (not via runbook):
# ssenv changes HOME, so always cd to /workspace first for Go test commands
cd /workspace
go build -o bin/skillshare ./cmd/skillshare
SKILLSHARE_TEST_BINARY="$PWD/bin/skillshare" go test ./tests/integration -count=1
go test ./...
Always run in devcontainer unless there is a documented exception.
Note: ssenv enter changes HOME, which may affect Go module resolution — always cd /workspace before running go test or go build.
--json Quick ReferenceMost commands support --json for structured output, making assertions more reliable than text matching.
| Command | --json | Notes |
|---------|----------|-------|
| ss status | --json | Skills, targets, sync status |
| ss list | --json / -j | All skills with metadata |
| ss target list | --json | Configured targets |
| ss install <src> | --json | Implies --force --all (skip prompts) |
| ss uninstall <name> | --json | Implies --force (skip prompts) |
| ss collect <path> | --json | Implies --force (skip prompts) |
| ss check | --json | Update availability per repo |
| ss update | --json | Update results per skill |
| ss diff | --json | Per-file diff details |
| ss sync | --json | Sync stats per target |
| ss audit | --format json | Also accepts --json (deprecated alias) |
| ss log | --json | Raw JSONL (one object per line) |
Key behaviors:
--json that implies --force / --all skips interactive prompts — safe for automationaudit prefers --format json; --json still works but is the deprecated formlog --json outputs JSONL (newline-delimited), not a JSON arrayjq# Count installed skills
ss list --json | jq 'length'
# Check a specific skill exists
ss list --json | jq -e '.[] | select(.name == "my-skill")'
# Verify target is configured
ss target list --json | jq -e '.[] | select(.name == "claude")'
# Assert no critical audit findings
ss audit --format json | jq -e '.summary.critical == 0'
# Check update availability
ss check --json | jq -e '.tracked_repos | length > 0'
# Verify sync succeeded (zero errors)
ss sync --json | jq -e '.errors == 0'
# Install and verify result
ss install https://github.com/user/repo --json | jq -e '.skills | length > 0'
When a jq -e expression fails (exit code 1 = false, 5 = no output), the step FAILs — no ambiguous text matching needed.
# Single command
docker exec $CONTAINER ssenv enter "$ENV_NAME" -- ss status
# JSON assertion (preferred for verification)
docker exec $CONTAINER ssenv enter "$ENV_NAME" -- bash -c '
ss list --json | jq -e ".[] | select(.name == \"my-skill\")"
'
# Multi-line compound command (use bash -c) — global mode flags
docker exec $CONTAINER ssenv enter "$ENV_NAME" -- bash -c '
ss init --no-copy --all-targets --no-git --no-skill
ss status
'
# Project mode init (different flag set!)
docker exec $CONTAINER env SKILLSHARE_DEV_ALLOW_WORKSPACE_PROJECT=1 \
ssenv enter "$ENV_NAME" -- bash -c '
cd /tmp/test-project && ss init -p --targets claude
'
# Check files (HOME is set to isolated path by ssenv)
docker exec $CONTAINER ssenv enter "$ENV_NAME" -- bash -c '
cat ~/.config/skillshare/config.yaml
'
# With environment variables
docker exec $CONTAINER ssenv enter "$ENV_NAME" -- bash -c '
TARGET=~/.claude/skills
ls -la "$TARGET"
'
# Go tests (must cd /workspace because ssenv changes HOME)
docker exec $CONTAINER ssenv enter "$ENV_NAME" -- bash -c '
cd /workspace
go test ./internal/install -run TestParseSource -count=1
'
development
Technology-agnostic prompt generator that creates customizable AI prompts for scanning codebases and identifying high-quality code exemplars. Supports multiple programming languages (.NET, Java, JavaScript, TypeScript, React, Angular, Python) with configurable analysis depth, categorization methods, and documentation formats to establish coding standards and maintain consistency across development teams.
tools
Expert-level browser automation, debugging, and performance analysis using Chrome DevTools MCP. Use for interacting with web pages, capturing screenshots, analyzing network traffic, and profiling performance.
data-ai
Prompt for creating detailed feature implementation plans, following Epoch monorepo structure.
tools
Interactive prompt refinement workflow: interrogates scope, deliverables, constraints; copies final markdown to clipboard; never writes code. Requires the Joyride extension.