Repository navigation
test(webui): cover automation lifecycle E2E - #7059
Conversation
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
|
🚅 Deployed to the ironclaw-pr-7059 environment in ironclaw-ci-preview
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughSummary by CodeRabbit
WalkthroughThe PR adds stable automation selectors, expands automation polling, and replaces the rename-only smoke test with creation, rename, pause, resume, reload, deletion, API verification, and failure-safe cleanup. ChangesAutomation lifecycle validation
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant Chat
participant WebUI
participant AutomationAPI
Chat->>AutomationAPI: Create automation
WebUI->>AutomationAPI: Rename automation
WebUI->>AutomationAPI: Pause automation
WebUI->>AutomationAPI: Read paused state after reload
WebUI->>AutomationAPI: Resume automation
WebUI->>AutomationAPI: Delete automation
WebUI->>AutomationAPI: Verify absence
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
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. Comment |
|
@claude review |
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@tests/e2e/scenarios/test_reborn_webui_v2_smoke.py`:
- Line 1278: Update the confirmation visibility wait in the delete scenario to
pass the same explicit 15000 ms timeout used by the other browser waits,
preserving the existing expect(confirmation) assertion.
- Around line 213-267: Consolidate the duplicated polling logic from
_wait_for_automation_id and _wait_for_automation_named into one shared poll
helper that accepts a predicate for matching the response data. Move the common
request URL, query parameters, status validation, timeout handling, sleep
cadence, and last-response tracking into that helper, then have both existing
callers provide their automation-specific predicates while preserving their
current return values and timeout assertions.
- Around line 1214-1277: Replace the rendered-name role locators for pause,
resume, delete, and the deletion confirmation dialog in the automation flow with
ID-keyed SEL_V2 selectors or stable test-ID locators. Update each action and
visibility assertion to use the immutable automation_id, while retaining
server-state checks and avoiding dependence on button or dialog label text.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 739c6484-52e5-4667-9e80-7369f75aab93
📒 Files selected for processing (1)
tests/e2e/scenarios/test_reborn_webui_v2_smoke.py
🔎 Review · PR #7059
The target changed before this Run could finish. Automatic · PR opened · attempt 0 of 3 · cancelled after <1s Run details
|
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
crates/ironclaw_webui/frontend/src/pages/automations/components/automation-detail-panel.test.ts (1)
233-258: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winAdd coverage for the delete-dialog wrapper's stable selectors.
The "deletes only after confirming the shared dialog" test checks
ConfirmDialogprops directly throughcomponentProps, but it does not assert the new wrapperdiv'sdata-testid="automation-delete-dialog"anddata-automation-idattributes added inautomation-detail-panel.tsx.tests/e2e/helpers.py'sautomation_delete_dialog_forselector depends on that wrapper. UsenativeProps(rendered, "div")(already used for<form>in this file) to assert those attributes here, so a regression is caught by this fast component test instead of only by the E2E lifecycle test.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@crates/ironclaw_webui/frontend/src/pages/automations/components/automation-detail-panel.test.ts` around lines 233 - 258, Extend the test “AutomationDetailPanel deletes only after confirming the shared dialog” to inspect the rendered delete-dialog wrapper via nativeProps(rendered, "div"), and assert its data-testid is "automation-delete-dialog" and data-automation-id is "automation-alpha" alongside the existing ConfirmDialog assertions.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In
`@crates/ironclaw_webui/frontend/src/pages/automations/components/automation-detail-panel.test.ts`:
- Around line 233-258: Extend the test “AutomationDetailPanel deletes only after
confirming the shared dialog” to inspect the rendered delete-dialog wrapper via
nativeProps(rendered, "div"), and assert its data-testid is
"automation-delete-dialog" and data-automation-id is "automation-alpha"
alongside the existing ConfirmDialog assertions.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 5fa45d4a-a940-4efe-a424-cd5c1e0aa677
📒 Files selected for processing (4)
crates/ironclaw_webui/frontend/src/pages/automations/components/automation-detail-panel.test.tscrates/ironclaw_webui/frontend/src/pages/automations/components/automation-detail-panel.tsxtests/e2e/helpers.pytests/e2e/scenarios/test_reborn_webui_v2_smoke.py
650ec7e to
462da6f
Compare
…-lifecycle-e2e # Conflicts: # scripts/ci/test_reborn_pr_test_plan.py
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@tests/e2e/scenarios/test_reborn_webui_v2_smoke.py`:
- Around line 1270-1273: Update tests/CLAUDE.md to document the materially
expanded test_reborn_v2_automation_lifecycle_persists_from_ui scenario, revise
its coverage-map entry from rename-only coverage to the full automation
lifecycle, and maintain the §6 scenario counts to reflect the change.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 08bf4219-4c25-4591-a449-88f7928a9689
📒 Files selected for processing (4)
crates/ironclaw_webui/frontend/src/pages/automations/components/automation-detail-panel.test.tscrates/ironclaw_webui/frontend/src/pages/automations/components/automation-detail-panel.tsxtests/e2e/helpers.pytests/e2e/scenarios/test_reborn_webui_v2_smoke.py
* test(webui): cover automation lifecycle E2E * test(webui): stabilize automation lifecycle E2E * ci: map E2E paths to dedicated workflow * chore(ci): drop superseded E2E planner mapping * docs(test): update automation lifecycle coverage map
Summary
Linked Issue
Closes #7056
Validation
cd tests/e2e && pytest scenarios/test_reborn_webui_v2_smoke.py -k automation -q4 passed, 38 deselectedpython -m py_compile tests/e2e/scenarios/test_reborn_webui_v2_smoke.pygit diff --checkTest Strategy
User behavior:
A user can create an Automation through Chat, rename it, pause and resume it across reloads, and delete it from the WebUI.
Risk areas:
Tests added or updated:
What the tests prove:
Every lifecycle mutation reaches the real API, survives reload where applicable, and is confirmed through API read-back. Deletion is verified by both exact-row UI absence and exact-ID API absence.
Security Impact
None. Test-only change with no authentication, authorization, or secret-handling changes.
Database Impact
None. No schema or migration changes.
Blast Radius
Limited to the existing Automation WebUI smoke E2E scenario.
Rollback Plan
Revert commit
998f6f982to restore the previous create-and-rename-only coverage.Review track: A