Skip to content

Bring the shell to the front before posting keys in the backspace tests - #3851

Open
vogella wants to merge 1 commit into
eclipse-platform:masterfrom
vogella:tests-activate-shell-before-post
Open

vogella wants to merge 1 commit into
eclipse-platform:masterfrom
vogella:tests-activate-shell-before-post

Conversation

@vogella

@vogella vogella commented Nov 12, 2026

Copy link
Copy Markdown
Contributor

Text and StyledText test_backspaceAndDelete only open the shell before calling Display.post, so on a busy machine the shell can stay behind another window and the posted keys go there; on Windows 11 this fails with "expected: <1> but was: <0>", because a background process may not take the foreground. The new SwtTestUtil.forceActiveForPost activates the shell before the keys are posted, and on Windows and Cocoa waits for it and skips the test instead of failing when it cannot become active. On GTK it only requests activation, since getActiveShell reports the wrong shell there (#726). This makes the two tests reliable on developer machines and keeps posted keys out of other applications' windows; they stay disabled on Jenkins as described in #2571.

Text and StyledText test_backspaceAndDelete only open the shell before Display.post, so on a busy machine the shell can stay behind another window and the posted keys go there ("expected: <1> but was: <0>" on Windows 11, where a background process may not take the foreground). SwtTestUtil.forceActiveForPost activates the shell, and outside GTK, where getActiveShell is reliable, waits for it and skips the test when it still is not active.

Assisted-by: multiple AI agents and layers of automated tooling 🤖
@github-actions

Copy link
Copy Markdown
Contributor

Test Results

 1 090 files  +  180   1 090 suites  +180   1h 36m 49s ⏱️ + 25m 14s
 5 228 tests ±    0   5 200 ✅ ±    0     28 💤 ±  0  0 ❌ ±0 
30 898 runs  +5 115  27 699 ✅ +4 515  3 199 💤 +600  0 ❌ ±0 

Results for commit b2206bd. ± Comparison against base commit a67dc32.

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