From 03c4d008ac3e3015e0d24a86aff9778f99ac89d4 Mon Sep 17 00:00:00 2001 From: Tobias Hahnen Date: Mon, 9 Dec 2024 11:46:29 +0100 Subject: [PATCH] NO-JIRA: Adjust tests to Eclipse 4.34 (2024-12) The combo box item was renamed to "Plain Text Editor" --- .../reddeer/preferences/FileAssociationsPreferences.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/its/org.sonarlint.eclipse.its.shared/src/org/sonarlint/eclipse/its/shared/reddeer/preferences/FileAssociationsPreferences.java b/its/org.sonarlint.eclipse.its.shared/src/org/sonarlint/eclipse/its/shared/reddeer/preferences/FileAssociationsPreferences.java index c1b8fe768..0a2a53fa8 100644 --- a/its/org.sonarlint.eclipse.its.shared/src/org/sonarlint/eclipse/its/shared/reddeer/preferences/FileAssociationsPreferences.java +++ b/its/org.sonarlint.eclipse.its.shared/src/org/sonarlint/eclipse/its/shared/reddeer/preferences/FileAssociationsPreferences.java @@ -45,7 +45,12 @@ public static FileAssociationsPreferences open() { } public void resetFileAssociation() { - new DefaultCombo(this, new WithLabelMatcher(LABEL)).setSelection("System Editor; if none: Text Editor"); + // With Eclipse 4.34 (2024-12) they changed the label inside the combo box from "Text Editor" to "Plain Text Editor" + try { + new DefaultCombo(this, new WithLabelMatcher(LABEL)).setSelection("System Editor; if none: Text Editor"); + } catch (RedDeerException ignored) { + new DefaultCombo(this, new WithLabelMatcher(LABEL)).setSelection("System Editor; if none: Plain Text Editor"); + } } public void enforceFileAssociation() {