Skip to content

test(e2e): add hermetic CLI E2E and unify test structure#48

Merged
saraeloop merged 1 commit intomainfrom
ci/hermetic-e2e-and-release
Apr 14, 2026
Merged

test(e2e): add hermetic CLI E2E and unify test structure#48
saraeloop merged 1 commit intomainfrom
ci/hermetic-e2e-and-release

Conversation

@saraeloop
Copy link
Copy Markdown
Member

Summary

Adds a minimal hermetic E2E path against the built CLI and unifies the test structure under test/ with explicit separation via *.e2e.ts.

Changes

E2E

  • add test/e2e/cli.e2e.ts
  • runs built CLI (dist/cli/index.js) against a deterministic local lockfile fixture
  • asserts structural scan contract and isolated .depgraph persistence
  • avoids live registry dependency and brittle assertions

Test structure

  • move E2E under test/e2e/
  • separate execution via *.test.ts vs *.e2e.ts
  • pnpm test runs unit/integration only
  • pnpm run test:e2e runs E2E

CI / release

  • CI runs: install → test → build → test:e2e
  • publish workflow runs: test → build → test:e2e → pack dry-run → publish
  • add release:check and pack:dry-run
  • enforce via prepublishOnly

Behavior

  • no scoring changes
  • no output contract changes
  • no persistence changes

Notes

  • E2E validates built artifact, not source execution
  • does not yet cover live registry traversal, tarball install, or multi-environment behavior

- add built-artifact E2E test under test/e2e/cli.e2e.ts
- use deterministic local package-lock fixture and isolated temp workspace
- assert stable JSON contract markers and .depgraph persistence
- avoid brittle score assertions and live registry dependency

- add test:e2e, pack:dry-run, and release:check scripts
- wire release:check into prepublishOnly

- update CI to run: install -> test -> build -> test:e2e
- update publish workflow to include E2E and pack dry-run

- unify test structure under test/ while keeping E2E explicitly separated via *.e2e.ts pattern

verification:
- pnpm test
- pnpm run build
- pnpm run test:e2e
- pnpm run release:check
@saraeloop saraeloop merged commit 3e1c6f9 into main Apr 14, 2026
1 check passed
@saraeloop saraeloop self-assigned this Apr 14, 2026
@saraeloop saraeloop deleted the ci/hermetic-e2e-and-release branch April 14, 2026 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant