test(e2e): self-provision throwaway repo + secret/variable#48
Merged
Conversation
Make the e2e hermetic: create a throwaway repo (auto-init), seed one Actions variable and one sealed-box-encrypted secret (libsodium dev dep), run the cycles, then delete the repo (removes its secrets/variables) in teardown. No pre-existing org resources required. Phase 2 now applies a topic through repoSettingsCycle and verifies by re-fetch. README documents the required App permissions. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
Follow-up to #47 — makes the e2e harness hermetic instead of relying on pre-existing org repos/secrets.
Change
beforeAllnow provisions its own resources,afterAlltears them down:warden-e2e-<run>(auto-init → hasmain)libsodium-wrappersdev dep — GitHub requires libsodium encryption for secret values)Phase 2 (opt-in) now applies a topic through
repoSettingsCycle.applyand verifies by re-fetch — cleaned up by the repo deletion.App permissions it needs (documented in README)
Repository administration (create/delete repos) + Actions secrets & variables read+write, plus the read scopes the cycles touch.
Verification
npx tsc --noEmitclean (incl. e2e + libsodium types)npm teststill 468 (e2e excluded)npm run test:e2ewith no creds → 14 skipped, exit 0Activate by adding the
WARDEN_E2E_*repo secrets; then nightly /gh workflow run e2e.yml.🤖 Generated with Claude Code