diff --git a/.github/workflows/linuxUI.yml b/.github/workflows/linuxUI.yml index ac24e494..1ee20df0 100644 --- a/.github/workflows/linuxUI.yml +++ b/.github/workflows/linuxUI.yml @@ -18,7 +18,10 @@ jobs: run: | sudo apt-get update sudo apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 libgbm1 - sudo /usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 & + # Use 1920x1080 so the Java Projects view (rendered inside the Explorer + # sidebar) gets enough vertical space. With 1024x768 the sticky + # pane-header overlapped tree rows and intercepted click events. + sudo /usr/bin/Xvfb :99 -screen 0 1920x1080x24 > /dev/null 2>&1 & sleep 3 - name: Set up JDK 21 diff --git a/test/e2e-plans/java-dep-file-operations.yaml b/test/e2e-plans/java-dep-file-operations.yaml index b06d3532..bf8f1156 100644 --- a/test/e2e-plans/java-dep-file-operations.yaml +++ b/test/e2e-plans/java-dep-file-operations.yaml @@ -25,14 +25,32 @@ setup: timeout: 180 settings: java.configuration.checkProjectSettingsExclusions: false + workbench.startupEditor: "none" steps: - # ── Setup: wait for LS, focus Java Projects ── + # ── Setup: wait for LS, free Explorer space, focus Java Projects ── - id: "ls-ready" action: "waitForLanguageServer" verify: "Java Language Server is ready" timeout: 180 + # Free horizontal space (Chat panel can take ~210px on right side) + - id: "close-aux-bar" + action: "executeVSCodeCommand workbench.action.closeAuxiliaryBar" + verify: "Auxiliary bar (Chat) closed" + + # Free vertical space inside Explorer so JAVA PROJECTS gets room. + # Without this the Java Projects pane-header overlaps tree rows on + # 1024x768 CI displays and click events get intercepted by the sticky header. + - id: "collapse-outline" + action: "collapseSidebarSection OUTLINE" + + - id: "collapse-timeline" + action: "collapseSidebarSection TIMELINE" + + - id: "collapse-workspace-root" + action: "collapseWorkspaceRoot" + - id: "focus-java-projects" action: "run command Java Projects: Focus on Java Projects View" verify: "Java Projects view is focused" @@ -68,11 +86,22 @@ steps: timeout: 15 # ── Test 2: create new package ── + # Close the editor opened by the previous step. With link-with-editor on, + # an open editor causes the JAVA PROJECTS tree to auto-expand, pushing + # my-app right under the sticky pane-header where clicks get intercepted. + - id: "close-editors-before-pkg" + action: "run command View: Close All Editors" + + - id: "collapse-workspace-root-2" + action: "collapseWorkspaceRoot" + - id: "focus-java-projects-2" action: "run command Java Projects: Focus on Java Projects View" + waitBefore: 1 - id: "click-project-node-2" action: "click my-app tree item" + waitBefore: 1 - id: "trigger-new-resource-2" action: "clickTreeItemAction my-app New..." @@ -99,6 +128,9 @@ steps: action: "open file AppToRename.java" waitBefore: 3 + - id: "collapse-workspace-root-3" + action: "collapseWorkspaceRoot" + - id: "focus-java-projects-3" action: "run command Java Projects: Focus on Java Projects View" waitBefore: 3 @@ -146,6 +178,9 @@ steps: action: "open file AppToDelete.java" waitBefore: 5 + - id: "collapse-workspace-root-4" + action: "collapseWorkspaceRoot" + - id: "focus-java-projects-4" action: "run command Java Projects: Focus on Java Projects View" waitBefore: 2 diff --git a/test/e2e-plans/java-dep-project-explorer.yaml b/test/e2e-plans/java-dep-project-explorer.yaml index 1bdb3656..cc0a0eea 100644 --- a/test/e2e-plans/java-dep-project-explorer.yaml +++ b/test/e2e-plans/java-dep-project-explorer.yaml @@ -21,6 +21,7 @@ setup: timeout: 180 settings: java.configuration.checkProjectSettingsExclusions: false + workbench.startupEditor: "none" steps: # ── Wait for LS ready ── @@ -29,6 +30,20 @@ steps: verify: "Java Language Server is ready" timeout: 180 + # Free horizontal & vertical space so JAVA PROJECTS gets enough room. + - id: "close-aux-bar" + action: "executeVSCodeCommand workbench.action.closeAuxiliaryBar" + verify: "Auxiliary bar (Chat) closed" + + - id: "collapse-outline" + action: "collapseSidebarSection OUTLINE" + + - id: "collapse-timeline" + action: "collapseSidebarSection TIMELINE" + + - id: "collapse-workspace-root" + action: "collapseWorkspaceRoot" + # ── Test 1: javaProjectExplorer.focus ── - id: "focus-java-projects" action: "run command Java Projects: Focus on Java Projects View" @@ -45,11 +60,13 @@ steps: timeout: 15 # ── Test 2: linkWithFolderExplorer ── + # NOTE: action resolver only matches "expandTreeItem " — strings like + # "expand my-app tree item" silently fall back to command palette and no-op. - id: "expand-project" - action: "expand my-app tree item" + action: "expandTreeItem my-app" - id: "expand-src" - action: "expand src/main/java tree item" + action: "expandTreeItem src/main/java" waitBefore: 2 - id: "verify-package" @@ -60,7 +77,7 @@ steps: timeout: 15 - id: "expand-package" - action: "expand com.mycompany.app tree item" + action: "expandTreeItem com.mycompany.app" waitBefore: 2 - id: "verify-app-class" @@ -72,8 +89,12 @@ steps: timeout: 15 # ── Test 3: unlinkWithFolderExplorer ── + # Click the title-bar action ("Unlink with Editor") in the JAVA PROJECTS pane. + # When `config.java.dependency.syncWithFolderExplorer == true` (the default), + # the package contributes the Unlink button to overflow_10@20 — clickViewTitleAction + # locates it directly or via the "Views and More Actions..." overflow menu. - id: "unlink-editor" - action: "run command Java: Unlink with Editor" + action: 'clickViewTitleAction "Java Projects" "Unlink with Editor"' verify: "Editor unlinked from tree" - id: "open-rename-file" @@ -84,11 +105,12 @@ steps: verify: "Tree should not auto-expand to AppToRename" - id: "relink-editor" - action: "run command Java: Link with Editor" + action: 'clickViewTitleAction "Java Projects" "Link with Editor"' verify: "Editor re-linked with tree" # ── Test 4: revealInProjectExplorer ── - # Collapse all tree nodes, then reveal App.java from editor + # Collapse all tree nodes, then reveal App.java by right-clicking the editor tab + # → "Reveal in Java Project Explorer" (contributed to editor/title/context). - id: "collapse-all" action: "run command View: Collapse All" verify: "Collapse tree to reset state" @@ -98,7 +120,7 @@ steps: waitBefore: 2 - id: "reveal-in-project-explorer" - action: "run command Java: Reveal in Java Project Explorer" + action: 'contextMenuOnEditorTab "App.java" "Reveal in Java Project Explorer"' waitBefore: 2 - id: "verify-revealed"