# Test 226 SkillHub CLI
- Runs in Docker from source.
- Catalog URL: http://127.0.0.1:8126/skillhub/catalog.json
- Cache path: /tmp/test226/home/.anet/skillhub/catalog-cache.json


## 1. Online list writes cache and shows cache path under --verbose
[anet] Skill cache: /tmp/test226/home/.anet/skillhub/catalog-cache.json
demo-skill	Demo Skill	Fixture skill for anet skill commands.	1.0.0
[anet] Cache path: /tmp/test226/home/.anet/skillhub/catalog-cache.json
PASS: skill list shows slug
PASS: skill list shows name
PASS: verbose output shows cache path
PASS: catalog cache written

## 2. Online show verifies sha256 and prints SKILL.md
[anet] Skill cache: /tmp/test226/home/.anet/skillhub/catalog-cache.json
# Demo Skill

Use this fixture.
[anet] Verified sha256: 71cd04f83fc233872e22bd235d197260f97b9df0341c45e36eff27bcb22f695b
PASS: skill show prints content
PASS: skill show reports verification under verbose

## 3. Offline list uses cache with time, source URL, and path
[anet] Using local SkillHub cache: /tmp/test226/home/.anet/skillhub/catalog-cache.json
[anet] Cache time: 2026-08-26T23:13:49.899Z
[anet] Cache source: http://127.0.0.1:8126/skillhub/catalog.json
demo-skill	Demo Skill	Fixture skill for anet skill commands.	1.0.0
PASS: offline cache use is explicit
PASS: offline cache time printed
PASS: offline cache source printed
PASS: offline cache path printed

## 4. Offline without cache names failed URL
[anet] FATAL: Error: Cannot read http://127.0.0.1:8126/skillhub/catalog.json and no local cache exists at /tmp/test226/no-cache-home/.anet/skillhub/catalog-cache.json
    at loadSkillCatalog (/app/agent-network/bin/cli.ts:3494:15)
    at async skillCommand (/app/agent-network/bin/cli.ts:3522:31)
    at async main (/app/agent-network/bin/cli.ts:15194:23)
    at processTicksAndRejections (native:7:39)
PASS: offline no-cache error names URL
PASS: offline no-cache error is clear

## 5. Witnessed-red: same bad fixture accepted without verification, rejected by anet
# Demo Skill

Use this fixture.
PASS: witness baseline: bad content accepted when sha256 is not checked
[anet] FATAL: Error: sha256 mismatch for demo-skill: expected 0000000000000000000000000000000000000000000000000000000000000000, got 71cd04f83fc233872e22bd235d197260f97b9df0341c45e36eff27bcb22f695b
    at fetchSkillContent (/app/agent-network/bin/cli.ts:3513:15)
    at async skillCommand (/app/agent-network/bin/cli.ts:3546:24)
    at async main (/app/agent-network/bin/cli.ts:15194:23)
    at processTicksAndRejections (native:7:39)
PASS: witness red: anet rejects mismatched sha256
PASS: mismatched content was not printed

## Summary
- Results: 15 passed, 0 failed
