Skip to content

Commit a192eaa

Browse files
committed
test: update worktree integration tests for branch input handling
- Added functionality to select "Other branch" in the edit feature dialog, enabling the branch input field. - Updated the locator for the branch input from 'edit-feature-branch' to 'edit-feature-input' for consistency across tests.
1 parent 99fe6f6 commit a192eaa

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

apps/app/tests/worktree-integration.spec.ts

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2414,8 +2414,12 @@ test.describe("Worktree Integration Tests", () => {
24142414
const editDialog = page.locator('[data-testid="edit-feature-dialog"]');
24152415
await expect(editDialog).toBeVisible({ timeout: 5000 });
24162416

2417+
// Select "Other branch" to enable the branch input
2418+
const otherBranchRadio = page.locator('label[for="edit-feature-other"]');
2419+
await otherBranchRadio.click();
2420+
24172421
// Find and click on the branch input to open the autocomplete
2418-
const branchInput = page.locator('[data-testid="edit-feature-branch"]');
2422+
const branchInput = page.locator('[data-testid="edit-feature-input"]');
24192423
await branchInput.click();
24202424
await page.waitForTimeout(300);
24212425

@@ -2509,7 +2513,7 @@ test.describe("Worktree Integration Tests", () => {
25092513
await expect(editDialog).toBeVisible({ timeout: 5000 });
25102514

25112515
// Find and click on the branch input
2512-
const branchInput = page.locator('[data-testid="edit-feature-branch"]');
2516+
const branchInput = page.locator('[data-testid="edit-feature-input"]');
25132517
await branchInput.click();
25142518
await page.waitForTimeout(300);
25152519

@@ -2568,7 +2572,7 @@ test.describe("Worktree Integration Tests", () => {
25682572
await expect(editDialog).toBeVisible({ timeout: 5000 });
25692573

25702574
// Change to the existing branch
2571-
const branchInput = page.locator('[data-testid="edit-feature-branch"]');
2575+
const branchInput = page.locator('[data-testid="edit-feature-input"]');
25722576
await branchInput.click();
25732577
await page.waitForTimeout(300);
25742578

0 commit comments

Comments
 (0)