fix: resolve 25 E2E test gaps — 10 pass → 31 pass#30
Merged
Conversation
Audit and fix naming inconsistencies across ~25 CLI subcommands: - Duration/Expiry: --expiry → --timeout (pair), --days → --expires-in-days (extend), add --days alias everywhere --expires-in-days appears - Key aliases: --alias → --key-alias (key commands), --key → --agent-key-alias (agent unlock), add --ika/--dka shorthand aliases - DID flags: --subject → --subject-did, --member → --member-did, add --device/ --issuer/--witness aliases to existing *-did flags - Output flags: --file → --output (emergency report) - Verb consistency: witness serve → start, org init → create - All renames preserve old names as visible aliases for discoverability
Tests were skipping due to wrong arguments, missing setup steps, and incorrect data formats. The CLI commands all existed — the tests just called them incorrectly. Test fixes: - device attestation: add --device-did (from status --json), use "main" alias, rewrite attest tests to use device link, implement device verify with exported attestation file + --issuer-pk - git signing: generate allowed-signers with --repo before verify, fix --repo to point at AUTHS_HOME, use auths:main alias - identity lifecycle: add --alias main and --max-age-secs to export-bundle - key rotation: add --yes to freeze/unfreeze, add allowed-signers for verify, rewrite attest to device link - policy engine: rewrite policy JSON to tagged enum format (op/args), fix context/test-case JSON to use issuer/subject/capabilities/expires_at, check stderr for explain output CLI fixes: - policy lint: bail on invalid JSON so exit code is non-zero - id export-bundle: rename output → output_file to avoid clap panic from field-name collision with global --output (OutputFormat) arg Helpers added: - get_identity_did(): controller DID from id show --json - get_device_did(): device DID from status --json - export_attestation(): extract attestation JSON from auths git repo Remaining 5 skips are OIDC bridge tests (tracked in #29). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
policy lintto return non-zero exit code on invalid JSONid export-bundleclap panic caused by field-name collision with global--outputargget_identity_did(),get_device_did(), andexport_attestation()test helpersResults
Remaining 5 skips are OIDC bridge tests (tracked in #29).
Test plan
uv run pytest -v— 31 passed, 5 skipped, 0 failedcargo clippy --all-targets --all-features -- -D warnings— cleancargo fmt --check --all— clean🤖 Generated with Claude Code