Skip to content

refactor(e2e): table lifecycle hook marker specs in config apply - #1614

Merged
skevetter merged 2 commits into
mainfrom
refactor/e2e-config-apply-lifecycle-table
Oct 20, 2026
Merged

skevetter merged 2 commits into
mainfrom
refactor/e2e-config-apply-lifecycle-table

Conversation

@skevetter

@skevetter skevetter commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Replaces five copy-pasted ginkgo.It specs in e2e/tests/configapply/configapply.go (postCreate, postStart, onCreate, updateContent, postAttach lifecycle-marker checks) with one ginkgo.DescribeTable. Only that file changes.

Why

The five specs differed only by hook key and marker path. One table removes about 110 duplicated lines and keeps marker assertions in one place.

Spec names, labels and counts are unchanged: Ginkgo dry-run JSON before and after, 503 specs, identical full names and labels. The empty table description is deliberate (commented in the file); a non-empty one would add a container segment to every name.

Spec order inside the Ordered container changes: the table now runs first. The specs are independent (own container and temp dir).

Validation

  • Head 80336bb5f = signed merge of origin/main 12c80dccf into the branch (no force push). Final diff vs origin/main: only e2e/tests/configapply/configapply.go.
  • go tool ginkgo --dry-run ./e2e: 503 specs, names/labels match the pre-change baseline.
  • go vet ./e2e/...: clean. gofmt -l: clean.
  • mise run cli:lint:ci: 0 issues (first run hit a parallel golangci-lint lock; rerun clean).
  • mise run cli:test:e2e:suite config-apply: 9 passed, 494 skipped (local Docker).
  • go test ./e2e/framework/...: ok (pre-merge run).
  • PR CI Test config-apply on ubuntu-latest (run 39395461260, job 118561903116): passed on 80336bb, 9 specs.

CodeRabbit CLI

coderabbit review --agent --committed --base-commit 12c80dccf: completed, 0 findings, reviewed e2e/tests/configapply/configapply.go. Earlier attempts on the pre-merge base were rate-limited; the third succeeded.

Auto-merge

Eligible: yes. Source lines changed: 0. Spec lines changed: 134 (21 added, 113 removed). Spec-file half-weight: 67. Files: 1.

Next

  • Reviewer confirms the empty table description is acceptable.

Summary by CodeRabbit

  • Tests
    • Consolidated lifecycle hook coverage into a parameterized test suite.
    • Verified behavior for post-create, post-start, on-create, content-update, and post-attach commands, including execution markers and timeout handling.

@skevetter skevetter added the e2e-refactor e2e refactor label Oct 20, 2026
@netlify

netlify Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for images-devsy-sh canceled.

Name Link
🔨 Latest commit 80336bb
🔍 Latest deploy log https://app.netlify.com/projects/images-devsy-sh/deploys/6ad729b0bd44ee44eacc9565

@netlify

netlify Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for devsydev canceled.

Name Link
🔨 Latest commit 80336bb
🔍 Latest deploy log https://app.netlify.com/projects/devsydev/deploys/6ad729b0fd5cfeab2aafed88

@coderabbitai

coderabbitai Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 269ab276-4010-4e5d-b5c9-be20e5bc2de5
📥 Commits

Reviewing files that changed from the base of the PR and between 12c80dc and 80336bb.

📒 Files selected for processing: 1
  • e2e/tests/configapply/configapply.go

Included review availability: This review used your included allowance. Your plan provides up to 2 included reviews per hour; 0 remain after this review.

📝 Walkthrough

The lifecycle hook tests in configapply.go now use a parameterized table. The table covers five hooks with shared setup, execution, marker verification, and timeout handling.

Changes: Lifecycle hook test consolidation

Layer / File(s) Summary
Parameterized lifecycle hook coverage
e2e/tests/configapply/configapply.go
The tests use a DescribeTable for postCreateCommand, postStartCommand, onCreateCommand, updateContentCommand, and postAttachCommand. Each entry uses shared setup, runs config apply, verifies the marker, and applies timeout handling.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~5 minutes

Change: Refactor

Merge Risk: ⚪ Minimal · up to 80336

The consolidated tests retain coverage of all five lifecycle hooks and are ready to merge after normal checks.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title clearly describes the main change: consolidating lifecycle hook marker specifications into a table in the config-apply end-to-end tests.
Description check Passed The description clearly explains what changed, why it changed, scope, intentional behavior details, and validation results. It does not reproduce all template sections, such as the change-type checkli…
Docstring Coverage Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description clearly explains what changed, why it changed, scope, intentional behavior details, and validation results. It does not reproduce all template sections, such as the change-type checklist, AI assistance declaration, and repository checklist, but the core information is complete.

Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1 files.

✨ Finishing Touches
✨ Simplify code
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@skevetter
skevetter marked this pull request as ready for review October 20, 2026 10:27
@mergify

mergify Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

This pull request does not currently match the merge queue conditions, so it cannot be queued from here. The box comes back if it matches again.

@skevetter
skevetter merged commit 967db9b into main Oct 20, 2026
111 checks passed
@skevetter
skevetter deleted the refactor/e2e-config-apply-lifecycle-table branch October 20, 2026 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant