Skip to content

Commit cc6551b

Browse files
Adam WisniewskiAdam Wisniewski
authored andcommitted
Update copyright
Signed-off-by: Adam Wisniewski <awisniew@Adams-MacBook-Pro.local>
1 parent 8001439 commit cc6551b

File tree

5 files changed

+37
-4
lines changed

5 files changed

+37
-4
lines changed

tests/pom.xml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<properties>
2727
<mvnImportWait>12000</mvnImportWait>
2828
</properties>
29-
29+
3030
<build>
3131
<plugins>
3232
<plugin>
@@ -102,6 +102,16 @@
102102
<id>org.eclipse.lsp4e.jdt</id>
103103
<versionRange>0.0.0</versionRange>
104104
</requirement>
105+
<requirement>
106+
<type>p2-installable-unit</type>
107+
<id>org.eclipse.lsp4jakarta.jdt.core</id>
108+
<versionRange>0.0.0</versionRange>
109+
</requirement>
110+
<requirement>
111+
<type>p2-installable-unit</type>
112+
<id>org.eclipse.jdt.ls.core</id>
113+
<versionRange>0.0.0</versionRange>
114+
</requirement>
105115
</extraRequirements>
106116
</dependency-resolution>
107117
</configuration>

tests/resources/applications/maven/liberty-maven-test-app/src/main/liberty/config/server.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
-->
1414
<server description="Sample Servlet server">
1515
<featureManager>
16-
<feature>jakartaee-10.0</feature>
16+
<feature>jsp-3.1</feature>
1717
</featureManager>
1818

1919
<httpEndpoint host="*" httpPort="9080" httpsPort="9443" id="defaultHttpEndpoint" />

tests/resources/applications/maven/liberty-maven-test-wrapper-app/src/main/liberty/config/server.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
-->
1414
<server description="Sample Servlet server">
1515
<featureManager>
16-
<feature>jakartaee-10.0</feature>
16+
<feature>jsp-3.1</feature>
1717
</featureManager>
1818

1919
<httpEndpoint host="*" httpPort="9080" httpsPort="9443" id="defaultHttpEndpoint" />

tests/src/main/java/io/openliberty/tools/eclipse/test/it/LibertyPluginSWTBotLSP4JakartaTest.java

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*******************************************************************************
2-
* Copyright (c) 2022, 2023 IBM Corporation and others.
2+
* Copyright (c) 2023 IBM Corporation and others.
33
*
44
* This program and the accompanying materials are made available under the
55
* terms of the Eclipse Public License v. 2.0 which is available at
@@ -13,6 +13,7 @@
1313
package io.openliberty.tools.eclipse.test.it;
1414

1515
import static org.junit.jupiter.api.Assertions.assertTrue;
16+
import static org.junit.jupiter.api.Assertions.fail;
1617

1718
import java.io.File;
1819
import java.nio.file.Path;
@@ -111,6 +112,7 @@ public void testClassLevelSnippets() {
111112

112113
// Get type-ahead list
113114
List<String> typeAheadOptions = SWTBotPluginOperations.getTypeAheadList(bot, "MyClass.java", "", 0, 0);
115+
System.out.println("INFO: Type-ahead options found = " + Arrays.toString(typeAheadOptions.toArray()));
114116

115117
boolean allFound = true;
116118
List<String> missingOptions = new ArrayList<String>();
@@ -123,10 +125,14 @@ public void testClassLevelSnippets() {
123125

124126
assertTrue(allFound, "Missing type-ahead options: " + Arrays.toString(missingOptions.toArray()));
125127

128+
} catch (Exception e) {
129+
fail("Unexpected exception was thrown: " + e);
126130
} finally {
127131

128132
// Delete new file
133+
System.out.println("INFO: Deleting MyClass.java file");
129134
LibertyPluginTestUtils.deleteFile(new File(wrapperProjectPath + "/src/main/java/test/maven/liberty/web/app/MyClass.java"));
135+
130136
}
131137
}
132138

@@ -142,6 +148,7 @@ public void testInClassSnippets() {
142148

143149
// Get type-ahead list
144150
List<String> typeAheadOptions = SWTBotPluginOperations.getTypeAheadList(bot, "MyClass.java", "", 3, 0);
151+
System.out.println("INFO: Type-ahead options found = " + Arrays.toString(typeAheadOptions.toArray()));
145152

146153
boolean allFound = true;
147154
List<String> missingOptions = new ArrayList<String>();
@@ -154,9 +161,12 @@ public void testInClassSnippets() {
154161

155162
assertTrue(allFound, "Missing type-ahead options: " + Arrays.toString(missingOptions.toArray()));
156163

164+
} catch (Exception e) {
165+
fail("Unexpected exception was thrown: " + e);
157166
} finally {
158167

159168
// Delete new file
169+
System.out.println("INFO: Deleting MyClass.java file");
160170
LibertyPluginTestUtils.deleteFile(new File(wrapperProjectPath + "/src/main/java/test/maven/liberty/web/app/MyClass.java"));
161171
}
162172
}
@@ -193,9 +203,12 @@ public void testDiagnosticsAndQuickFixes() {
193203

194204
assertTrue(allFound, "Missing quick-fixes: " + Arrays.toString(missingFixes.toArray()));
195205

206+
} catch (Exception e) {
207+
fail("Unexpected exception was thrown: " + e);
196208
} finally {
197209

198210
// Delete new file
211+
System.out.println("INFO: Deleting MyClass.java file");
199212
LibertyPluginTestUtils.deleteFile(new File(wrapperProjectPath + "/src/main/java/test/maven/liberty/web/app/MyClass.java"));
200213
}
201214
}

tests/src/main/java/io/openliberty/tools/eclipse/test/it/utils/SWTBotPluginOperations.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -933,6 +933,8 @@ public boolean matches(Object object) {
933933
*/
934934
public static void createNewClass(SWTWorkbenchBot bot, String appName, String className, boolean clearContent) {
935935

936+
System.out.println("INFO: Creating new Java class: " + className);
937+
936938
Object project = getAppInPackageExplorerTree(appName);
937939
context(project, "New", "Class");
938940

@@ -966,6 +968,9 @@ public static void createNewClass(SWTWorkbenchBot bot, String appName, String cl
966968
*/
967969
public static List<String> getTypeAheadList(SWTWorkbenchBot bot, String editorFileName, String insertText, int cursorRow,
968970
int cursorColumn) {
971+
972+
System.out.println("INFO: Getting type-ahead list");
973+
969974
SWTBotPreferences.PLAYBACK_DELAY = 1000;
970975

971976
SWTBotEditor editor = searchForEditor(bot, editorFileName);
@@ -991,6 +996,9 @@ public static List<String> getTypeAheadList(SWTWorkbenchBot bot, String editorFi
991996
*/
992997
public static void selectTypeAheadOption(SWTWorkbenchBot bot, String editorFileName, String option, int cursorRow,
993998
int cursorColumn) {
999+
1000+
System.out.println("INFO: Selecting type-ahead option: " + option);
1001+
9941002
SWTBotPreferences.PLAYBACK_DELAY = 1000;
9951003
SWTBotEditor editor = searchForEditor(bot, editorFileName);
9961004
SWTBotEclipseEditor e = editor.toTextEditor();
@@ -1008,6 +1016,8 @@ public static void selectTypeAheadOption(SWTWorkbenchBot bot, String editorFileN
10081016
* @return
10091017
*/
10101018
public static List<String> getQuickFixList(SWTWorkbenchBot bot, String editorFileName) {
1019+
System.out.println("INFO: Getting quick-fix list for class: " + editorFileName);
1020+
10111021
SWTBotPreferences.PLAYBACK_DELAY = 1000;
10121022

10131023
SWTBotEditor editor = searchForEditor(bot, editorFileName);

0 commit comments

Comments
 (0)