JBoss Tools SVN: r41780 - branches/jbosstools-3.3.x/build.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2012-06-07 12:04:30 -0400 (Thu, 07 Jun 2012)
New Revision: 41780
Modified:
branches/jbosstools-3.3.x/build/publish.sh
Log:
support Jenkins better
Modified: branches/jbosstools-3.3.x/build/publish.sh
===================================================================
--- branches/jbosstools-3.3.x/build/publish.sh 2012-06-07 15:50:49 UTC (rev 41779)
+++ branches/jbosstools-3.3.x/build/publish.sh 2012-06-07 16:04:30 UTC (rev 41780)
@@ -1,4 +1,9 @@
#!/bin/bash
script=$0
-script=${script/publish.sh/publish\/publish.sh}
+if [[ ${script%%publish.sh} != $script ]]; then
+ script=${script/publish.sh/publish\/publish.sh}
+else
+ script=$1
+ script=${script/publish.sh/publish\/publish.sh}
+fi
. ${script}
13 years, 4 months
JBoss Tools SVN: r41779 - trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot.
by jbosstools-commits@lists.jboss.org
Author: rhopp
Date: 2012-06-07 11:50:49 -0400 (Thu, 07 Jun 2012)
New Revision: 41779
Modified:
trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CentralAllBotTests.java
trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CreateProjectsWithServerTest.java
trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/DocumentationSectionTest.java
Log:
Little tweaks
Modified: trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CentralAllBotTests.java
===================================================================
--- trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CentralAllBotTests.java 2012-06-07 15:47:27 UTC (rev 41778)
+++ trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CentralAllBotTests.java 2012-06-07 15:50:49 UTC (rev 41779)
@@ -7,10 +7,11 @@
@RunWith(RequirementAwareSuite.class)
@SuiteClasses({
BaseFunctionalityTest.class,
-// CreateProjectsWithServerTest.class,
+ CreateProjectsWithServerTest.class,
// CreateProjectsWithoutServerTest.class
DocumentationSectionTest.class
- //EmptyTestForHudson.class
+// EmptyTestForHudson.class
+// InstallTest.class
})
public class CentralAllBotTests {
Modified: trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CreateProjectsWithServerTest.java
===================================================================
--- trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CreateProjectsWithServerTest.java 2012-06-07 15:47:27 UTC (rev 41778)
+++ trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/CreateProjectsWithServerTest.java 2012-06-07 15:50:49 UTC (rev 41779)
@@ -1,15 +1,9 @@
package org.jboss.tools.central.test.ui.bot;
-import static org.eclipse.swtbot.swt.finder.matchers.WidgetMatcherFactory.widgetOfType;
-
import java.io.File;
import java.io.FileNotFoundException;
-import org.eclipse.swt.widgets.Link;
-import org.eclipse.swtbot.eclipse.finder.waits.Conditions;
import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException;
-import org.eclipse.swtbot.swt.finder.utils.Traverse;
-import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotShell;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
import org.jboss.tools.ui.bot.ext.SWTBotFactory;
@@ -18,7 +12,7 @@
import org.jboss.tools.ui.bot.ext.condition.NonSystemJobRunsCondition;
import org.jboss.tools.ui.bot.ext.config.Annotations.Require;
import org.jboss.tools.ui.bot.ext.config.Annotations.ServerType;
-import org.jboss.tools.ui.bot.ext.gen.ActionItem.Preference;
+import org.jboss.tools.ui.bot.ext.parts.SWTBotFormTextExt;
import org.jboss.tools.ui.bot.ext.parts.SWTBotTwistie;
import org.jboss.tools.ui.bot.ext.types.IDELabel;
import org.jboss.tools.ui.bot.ext.view.ProblemsView;
@@ -29,11 +23,13 @@
//TODO When testing new build try it with type=ServerType.EAP !!!!
-@Require(server=(a)org.jboss.tools.ui.bot.ext.config.Annotations.Server(type=ServerType.JbossAS))
+@Require(clearProjects=false,server=(a)org.jboss.tools.ui.bot.ext.config.Annotations.Server(type=ServerType.JbossAS))
public class CreateProjectsWithServerTest extends SWTTestExt{
@BeforeClass
public static void setup() throws FileNotFoundException{
+ util.closeAllEditors(false);
+ util.closeAllViews();
bot.menu("Window").menu("Preferences").click();
bot.waitForShell("Preferences");
bot.tree().getTreeItem("Maven").select();
@@ -44,7 +40,6 @@
if (configuredState.getServer().type.equalsIgnoreCase("EAP")){
setupEAP();
}
-
}
/**
* Sets up maven configuration file with configured EAP and WFK repository and clears ~/.m2/clean-repository
@@ -52,7 +47,6 @@
* @throws FileNotFoundException
*/
private static void setupEAP() throws FileNotFoundException{
- log.info("A mame tady EAPcko !!!!!!");
String mvnConfigFileName = System.getProperty("eap.maven.config.file");
File mvnConfigFile;
try {
@@ -107,7 +101,7 @@
}
- @Test
+// @Test
public void createProjectsSectionTest(){
//Dynamic web project
bot.hyperlink(IDELabel.JBossCentralEditor.DYNAMIC_WEB_PROJECT).click();
@@ -139,7 +133,7 @@
projectExampleShell.close();
//check the rest of project examples
- checkExample(null, IDELabel.JBossCentralEditor.JAVA_EE_WEB_PROJECT, false);
+ checkExample(null, IDELabel.JBossCentralEditor.JAVA_EE_WEB_PROJECT, true);
checkExample(null, IDELabel.JBossCentralEditor.JAVA_EE_PROJECT, true);
checkExample(null, IDELabel.JBossCentralEditor.HTML5_PROJECT, true);
checkExample(null, IDELabel.JBossCentralEditor.RICHFACES_PROJECT, true);
@@ -238,7 +232,12 @@
if (formsBot==null){
bot.hyperlink(formText).click();
}else{
- formsBot.formTextWithText(formText).click();
+ try{
+ formsBot.formTextWithText(formText).click();
+ }catch(WidgetNotFoundException wnfex){
+ throw new WidgetNotFoundException("Could not found widget of type Hyperlink and text " +
+ formText, wnfex);
+ }
}
bot.waitForShell(IDELabel.JBossCentralEditor.PROJECT_EXAMPLE);
SWTBotWizard wizard = new SWTBotWizard(bot.shell(IDELabel.JBossCentralEditor.PROJECT_EXAMPLE).widget);
Modified: trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/DocumentationSectionTest.java
===================================================================
--- trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/DocumentationSectionTest.java 2012-06-07 15:47:27 UTC (rev 41778)
+++ trunk/central/tests/org.jboss.tools.central.test.ui.bot/src/org/jboss/tools/central/test/ui/bot/DocumentationSectionTest.java 2012-06-07 15:50:49 UTC (rev 41779)
@@ -37,7 +37,7 @@
bot.waitUntil(new BrowserIsLoaded(browser), TaskDuration.LONG.getTimeout());
assertFalse("JBoss Central sould not be active editor right now", bot.activeEditor().getTitle().equals("JBoss Central"));
//And also can't be empty page
- System.out.println(browser.getText());
+ //System.out.println(browser.getText());
Pattern pattern = Pattern.compile(".*<body></body>.*", Pattern.DOTALL);
Matcher matcher = pattern.matcher(browser.getText());
assertFalse("Page cannot be empty", matcher.matches());
13 years, 4 months
JBoss Tools SVN: r41778 - branches/jbosstools-3.3.x/build.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2012-06-07 11:47:27 -0400 (Thu, 07 Jun 2012)
New Revision: 41778
Modified:
branches/jbosstools-3.3.x/build/publish.sh
Log:
fix pointer to new build/publish/publish.sh script
Modified: branches/jbosstools-3.3.x/build/publish.sh
===================================================================
--- branches/jbosstools-3.3.x/build/publish.sh 2012-06-07 15:43:27 UTC (rev 41777)
+++ branches/jbosstools-3.3.x/build/publish.sh 2012-06-07 15:47:27 UTC (rev 41778)
@@ -1,3 +1,4 @@
#!/bin/bash
-cd `pwd`/publish
-./publish.sh
+script=$0
+script=${script/publish.sh/publish\/publish.sh}
+. ${script}
13 years, 4 months
JBoss Tools SVN: r41777 - trunk/cdi/tests/org.jboss.tools.cdi.seam3.bot.test.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-06-07 11:43:27 -0400 (Thu, 07 Jun 2012)
New Revision: 41777
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.seam3.bot.test/
Log:
target folder ignored for svn repo
Property changes on: trunk/cdi/tests/org.jboss.tools.cdi.seam3.bot.test
___________________________________________________________________
Modified: svn:ignore
- bin
screenshots
+ bin
screenshots
target
13 years, 4 months
JBoss Tools SVN: r41776 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/parts.
by jbosstools-commits@lists.jboss.org
Author: rhopp
Date: 2012-06-07 11:43:16 -0400 (Thu, 07 Jun 2012)
New Revision: 41776
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/parts/SWTBotFormTextExt.java
Log:
Clicking to FormText in Centra has been broken. This repairs it.
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/parts/SWTBotFormTextExt.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/parts/SWTBotFormTextExt.java 2012-06-07 15:39:35 UTC (rev 41775)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/parts/SWTBotFormTextExt.java 2012-06-07 15:43:16 UTC (rev 41776)
@@ -2,12 +2,11 @@
import java.lang.reflect.Field;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Event;
import org.eclipse.swtbot.swt.finder.ReferenceBy;
import org.eclipse.swtbot.swt.finder.SWTBotWidget;
import org.eclipse.swtbot.swt.finder.exceptions.WidgetNotFoundException;
import org.eclipse.swtbot.swt.finder.results.StringResult;
+import org.eclipse.swtbot.swt.finder.results.VoidResult;
import org.eclipse.swtbot.swt.finder.widgets.AbstractSWTBotControl;
import org.eclipse.ui.forms.widgets.FormText;
import org.eclipse.ui.internal.forms.widgets.FormTextModel;
@@ -36,8 +35,16 @@
}
public AbstractSWTBotControl<FormText> click() {
+ syncExec(new VoidResult() {
+
+ @Override
+ public void run() {
+ click(widget.toDisplay(25,5).x, widget.toDisplay(25,5).y, true); //+20 is there because of icon
+ }
+ });
+ /*old version of click
setFocus();
- keyboard().typeCharacter('\r');
+ keyboard().typeCharacter('\r');*/
return this;
}
13 years, 4 months
JBoss Tools SVN: r41775 - in trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest: validation and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-06-07 11:39:35 -0400 (Thu, 07 Jun 2012)
New Revision: 41775
Modified:
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/DefaultValueAnnotationSupportTest.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/MatrixAnnotationSupportTest.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/PathAnnotationSupportTest.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/QueryAnnotationSupportTest.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulHelper.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulTestBase.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/ApplicationPathAnnotationTest.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/RESTfulValidationTest.java
Log:
refactoring of ws bot tests
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/DefaultValueAnnotationSupportTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/DefaultValueAnnotationSupportTest.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/DefaultValueAnnotationSupportTest.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -12,7 +12,6 @@
package org.jboss.tools.ws.ui.bot.test.rest;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
-import org.jboss.tools.ws.ui.bot.test.ti.wizard.RESTFullExplorerWizard;
import org.junit.Test;
public class DefaultValueAnnotationSupportTest extends RESTfulTestBase {
@@ -32,9 +31,8 @@
/* prepare project */
importRestWSProject("default1");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("default1");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("default1");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
@@ -50,9 +48,8 @@
/* prepare project */
importRestWSProject("default2");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("default2");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("default2");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
@@ -67,9 +64,8 @@
/* prepare project */
importRestWSProject("default3");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("default3");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("default3");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/MatrixAnnotationSupportTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/MatrixAnnotationSupportTest.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/MatrixAnnotationSupportTest.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -13,7 +13,6 @@
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
import org.jboss.tools.ui.bot.ext.Timing;
-import org.jboss.tools.ws.ui.bot.test.ti.wizard.RESTFullExplorerWizard;
import org.junit.Test;
public class MatrixAnnotationSupportTest extends RESTfulTestBase {
@@ -42,9 +41,8 @@
/* prepare project */
importRestWSProject("matrix1");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("matrix1");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("matrix1");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
@@ -64,9 +62,8 @@
matrixParam1, matrixParamNew, true);
bot.sleep(Timing.time2S());
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("matrix1");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("matrix1");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
@@ -85,9 +82,8 @@
matrixParamType1, matrixParamTypeNew, true);
bot.sleep(Timing.time2S());
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("matrix1");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("matrix1");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/PathAnnotationSupportTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/PathAnnotationSupportTest.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/PathAnnotationSupportTest.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -14,7 +14,6 @@
import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEclipseEditor;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
import org.jboss.tools.ui.bot.ext.Timing;
-import org.jboss.tools.ws.ui.bot.test.ti.wizard.RESTFullExplorerWizard;
import org.junit.After;
import org.junit.Test;
@@ -37,9 +36,8 @@
/* import project */
importRestWSProject("restBasic");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("restBasic");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("restBasic");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 4);
@@ -53,9 +51,8 @@
/* import project */
importRestWSProject("restAdvanced");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("restAdvanced");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("restAdvanced");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 4);
@@ -74,9 +71,8 @@
"org.rest.test", "RestService.java").toTextEditor(), "@DELETE", "@GET", true);
bot.sleep(Timing.time2S());
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("restBasic");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("restBasic");
/* test JAX-RS REST explorer */
assertNotAllRESTServicesInExplorer(restServices);
@@ -99,9 +95,8 @@
+ LINE_SEPARATOR + "@Produces(\"text/plain\")", true);
bot.sleep(Timing.time2S());
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("restAdvanced");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("restAdvanced");
/* test JAX-RS REST explorer */
testEditedDeleteRestWebResource(restServices);
@@ -117,12 +112,11 @@
"org.rest.test", "RestService");
bot.sleep(Timing.time2S());
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("restBasic");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("restBasic");
/* none of REST web services found */
- assertNoRESTServicesInExplorerFound(restServices);
+ assertCountOfRESTServices(restServices, 0);
}
private void testEditedDeleteRestWebResource(
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/QueryAnnotationSupportTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/QueryAnnotationSupportTest.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/QueryAnnotationSupportTest.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -13,7 +13,6 @@
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
import org.jboss.tools.ui.bot.ext.Timing;
-import org.jboss.tools.ws.ui.bot.test.ti.wizard.RESTFullExplorerWizard;
import org.junit.Test;
public class QueryAnnotationSupportTest extends RESTfulTestBase {
@@ -39,9 +38,8 @@
/* prepare project */
importRestWSProject("query1");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("query1");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("query1");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
@@ -51,9 +49,8 @@
/* prepare project*/
importRestWSProject("query2");
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("query2");
- restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ restServices = restfulServicesForProject("query2");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
@@ -74,9 +71,8 @@
queryParam1, queryParam1New, true);
bot.sleep(Timing.time2S());
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("query2");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("query2");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
@@ -99,9 +95,8 @@
queryType1, queryTypeNew, true);
bot.sleep(Timing.time2S());
- /* get JAX-RS REST explorer for the project */
- restfulWizard = new RESTFullExplorerWizard("query2");
- SWTBotTreeItem[] restServices = restfulWizard.getAllRestServices();
+ /* get RESTful services from JAX-RS REST explorer for the project */
+ SWTBotTreeItem[] restServices = restfulServicesForProject("query2");
/* test JAX-RS REST explorer */
assertCountOfRESTServices(restServices, 1);
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulHelper.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulHelper.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulHelper.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -53,10 +53,18 @@
ADD, REMOVE;
}
- public SWTBotTreeItem[] getRESTValidationErrors(String wsProjectName) {
+ private SWTBotTreeItem[] getRESTValidationErrors(String wsProjectName, String description) {
return ProblemsView.getFilteredErrorsTreeItems(bot,
- PATH_PARAM_VALID_ERROR, "/" + wsProjectName, null, null);
+ description, "/" + wsProjectName, null, null);
}
+
+ public SWTBotTreeItem[] getPathAnnotationValidationErrors(String wsProjectName) {
+ return getRESTValidationErrors(wsProjectName, PATH_PARAM_VALID_ERROR);
+ }
+
+ public SWTBotTreeItem[] getApplicationAnnotationValidationErrors(String wsProjectName) {
+ return getRESTValidationErrors(wsProjectName, null);
+ }
public void enableRESTValidation() {
modifyRESTValidation(ConfigureOption.ADD);
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulTestBase.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulTestBase.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulTestBase.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -95,13 +95,6 @@
allRestServicesArePresent(restServices));
}
- protected void assertNoRESTServicesInExplorerFound(
- SWTBotTreeItem[] restServices) {
- assertTrue(restServices.length
- + " RESTful services was found instead of 0.",
- restServices.length == 0);
- }
-
protected void assertPathOfAllRESTWebServices(
SWTBotTreeItem[] restServices, String path) {
for (SWTBotTreeItem restService : restServices) {
@@ -144,13 +137,28 @@
assertEquals("Failure when comparing paths = ", expectedPath, path);
}
- protected void assertCoundOfValidationErrors(String projectName,
+ protected void assertCountOfPathAnnotationValidationErrors(String projectName,
int expectedCount) {
- int foundErrors = restfulHelper.getRESTValidationErrors(projectName).length;
- assertTrue("There should be " + expectedCount
- + " validation error. Found: " + foundErrors,
- foundErrors == expectedCount);
+ int foundErrors = restfulHelper.getPathAnnotationValidationErrors(projectName).length;
+ assertCountOfValidationError(expectedCount, foundErrors);
}
+
+ protected void assertCountOfApplicationAnnotationValidationErrors(String projectName,
+ int expectedCount) {
+ int foundErrors = restfulHelper.getPathAnnotationValidationErrors(projectName).length;
+ assertCountOfValidationError(expectedCount, foundErrors);
+ }
+
+ private void assertCountOfValidationError(int expectedCount, int foundCount) {
+ assertTrue("Expected count of validation errors: " + expectedCount
+ + ". Count of found validation errors: " + foundCount,
+ foundCount == expectedCount);
+ }
+
+ protected SWTBotTreeItem[] restfulServicesForProject(String projectName) {
+ restfulWizard = new RESTFullExplorerWizard(projectName);
+ return restfulWizard.getAllRestServices();
+ }
protected SWTBotEditor editorForClass(String projectName, String... path) {
return packageExplorer.openFile(projectName, path);
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/ApplicationPathAnnotationTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/ApplicationPathAnnotationTest.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/ApplicationPathAnnotationTest.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -16,12 +16,13 @@
import org.junit.Before;
import org.junit.Test;
+/**
+ *
+ * @author jjankovi
+ *
+ */
public class ApplicationPathAnnotationTest extends RESTfulTestBase {
- @Override
- public String getWsProjectName() {
- return "restApplication1";
- }
@Before
public void setup() {
@@ -34,13 +35,23 @@
}
@Test
- public void testMultipleAppClasses() {
+ public void testMultipleApplicationClasses() {
+ /* prepare project */
+ importRestWSProject("app1");
+
+ /* test validation error */
+ assertCountOfApplicationAnnotationValidationErrors("app1", 1);
}
@Test
- public void testWebXmlApplicationOption() {
+ public void testWebXmlAndApplicationClass() {
+ /* prepare project */
+ importRestWSProject("app2");
+
+ /* test validation error */
+ assertCountOfApplicationAnnotationValidationErrors("app2", 1);
}
}
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/RESTfulValidationTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/RESTfulValidationTest.java 2012-06-07 15:38:28 UTC (rev 41774)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/RESTfulValidationTest.java 2012-06-07 15:39:35 UTC (rev 41775)
@@ -46,7 +46,7 @@
GET_METHOD_PATH, CORRECT_PATH_PARAM);
/* test count of validation errors */
- assertCoundOfValidationErrors(getWsProjectName(), 0);
+ assertCountOfPathAnnotationValidationErrors(getWsProjectName(), 0);
}
@@ -62,7 +62,7 @@
GET_METHOD_PATH, BAD_PATH_PARAM);
/* test count of validation errors */
- assertCoundOfValidationErrors(getWsProjectName(), 1);
+ assertCountOfPathAnnotationValidationErrors(getWsProjectName(), 1);
}
@Test
@@ -79,7 +79,7 @@
GET_METHOD_PATH, BAD_PATH_PARAM);
/* test count of validation errors */
- assertCoundOfValidationErrors(getWsProjectName(), 1);
+ assertCountOfPathAnnotationValidationErrors(getWsProjectName(), 1);
}
@Test
@@ -96,7 +96,7 @@
GET_METHOD_PATH, CORRECT_PATH_PARAM);
/* test count of validation errors */
- assertCoundOfValidationErrors(getWsProjectName(), 0);
+ assertCountOfPathAnnotationValidationErrors(getWsProjectName(), 0);
}
@Test
@@ -113,13 +113,13 @@
GET_METHOD_PATH, BAD_PATH_PARAM);
/* test count of validation errors */
- assertCoundOfValidationErrors(getWsProjectName(), 0);
+ assertCountOfPathAnnotationValidationErrors(getWsProjectName(), 0);
/* enable restful validation */
restfulHelper.enableRESTValidation();
/* test count of validation errors */
- assertCoundOfValidationErrors(getWsProjectName(), 1);
+ assertCountOfPathAnnotationValidationErrors(getWsProjectName(), 1);
}
}
13 years, 4 months
JBoss Tools SVN: r41774 - in trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects: app1 and 13 other directories.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-06-07 11:38:28 -0400 (Thu, 07 Jun 2012)
New Revision: 41774
Added:
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.classpath
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.project
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/.jsdtscope
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.jdt.core.prefs
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.component
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.project.facet.core.xml
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.container
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.name
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/META-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/META-INF/MANIFEST.MF
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/WEB-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/WEB-INF/lib/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/build/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App2.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/RestService.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.classpath
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.project
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/.jsdtscope
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.jdt.core.prefs
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.component
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.project.facet.core.xml
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.container
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.name
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/META-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/META-INF/MANIFEST.MF
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/WEB-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/WEB-INF/lib/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/WEB-INF/web.xml
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/build/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/App.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/RestService.java
Log:
new resource projects for ApplicationAnnotationTest added
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.classpath
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.classpath (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.classpath 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/jdk1.6.0_29">
+ <attributes>
+ <attribute name="owner.project.facets" value="java"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.jst.server.core.container/org.jboss.ide.eclipse.as.core.server.runtime.runtimeTarget/JBoss 7.1.0 Runtime ">
+ <attributes>
+ <attribute name="owner.project.facets" value="jst.web"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.web.container"/>
+ <classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
+ <classpathentry kind="output" path="build/classes"/>
+</classpath>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.project
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.project (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.project 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>app1</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.wst.jsdt.core.javascriptValidator</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.common.project.facet.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.jboss.tools.ws.jaxrs.metamodelBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.validation.validationbuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
+ <nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
+ <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.eclipse.wst.jsdt.core.jsNature</nature>
+ <nature>org.jboss.tools.ws.jaxrs.nature</nature>
+ </natures>
+</projectDescription>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/.jsdtscope
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/.jsdtscope (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/.jsdtscope 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="WebContent"/>
+ <classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.WebProject">
+ <attributes>
+ <attribute name="hide" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.baseBrowserLibrary"/>
+ <classpathentry kind="output" path=""/>
+</classpath>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.jdt.core.prefs 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,7 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
+org.eclipse.jdt.core.compiler.compliance=1.6
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.source=1.6
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.component
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.component (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.component 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
+ <wb-module deploy-name="app1">
+ <wb-resource deploy-path="/" source-path="/WebContent" tag="defaultRootSource"/>
+ <wb-resource deploy-path="/WEB-INF/classes" source-path="/src"/>
+ <property name="context-root" value="app1"/>
+ <property name="java-output-path" value="/app1/build/classes"/>
+ </wb-module>
+</project-modules>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.project.facet.core.xml
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.project.facet.core.xml (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.common.project.facet.core.xml 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<faceted-project>
+ <runtime name="JBoss 7.1.0 Runtime "/>
+ <fixed facet="wst.jsdt.web"/>
+ <fixed facet="jst.web"/>
+ <fixed facet="java"/>
+ <installed facet="java" version="1.6"/>
+ <installed facet="jst.web" version="3.0"/>
+ <installed facet="wst.jsdt.web" version="1.0"/>
+</faceted-project>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.container
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.container (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.container 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1 @@
+org.eclipse.wst.jsdt.launching.baseBrowserLibrary
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.name
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.name (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/.settings/org.eclipse.wst.jsdt.ui.superType.name 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1 @@
+Window
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/META-INF/MANIFEST.MF
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/META-INF/MANIFEST.MF (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/WebContent/META-INF/MANIFEST.MF 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path:
+
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App.java (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App.java 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,19 @@
+package test;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.ws.rs.ApplicationPath;
+import javax.ws.rs.core.Application;
+
+@ApplicationPath("/path")
+public class App extends Application {
+
+ @Override
+ public Set<Class<?>> getClasses() {
+ Set<Class<?>> classes = new HashSet<Class<?>>();
+ classes.add(RestService.class);
+ return super.getClasses();
+ }
+
+}
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App2.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App2.java (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/App2.java 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,19 @@
+package test;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.ws.rs.ApplicationPath;
+import javax.ws.rs.core.Application;
+
+@ApplicationPath("/path")
+public class App2 extends Application {
+
+ @Override
+ public Set<Class<?>> getClasses() {
+ Set<Class<?>> classes = new HashSet<Class<?>>();
+ classes.add(RestService.class);
+ return super.getClasses();
+ }
+
+}
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/RestService.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/RestService.java (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app1/src/test/RestService.java 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,14 @@
+package test;
+
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+
+@Path("/rest")
+public class RestService {
+
+ @GET
+ public void method() {
+
+ }
+
+}
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.classpath
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.classpath (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.classpath 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/jdk1.6.0_29">
+ <attributes>
+ <attribute name="owner.project.facets" value="java"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.jst.server.core.container/org.jboss.ide.eclipse.as.core.server.runtime.runtimeTarget/JBoss 7.1.0 Runtime ">
+ <attributes>
+ <attribute name="owner.project.facets" value="jst.web"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.web.container"/>
+ <classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
+ <classpathentry kind="output" path="build/classes"/>
+</classpath>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.project
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.project (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.project 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>app2</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.wst.jsdt.core.javascriptValidator</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.common.project.facet.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.jboss.tools.ws.jaxrs.metamodelBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.validation.validationbuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
+ <nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
+ <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.eclipse.wst.jsdt.core.jsNature</nature>
+ <nature>org.jboss.tools.ws.jaxrs.nature</nature>
+ </natures>
+</projectDescription>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/.jsdtscope
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/.jsdtscope (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/.jsdtscope 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="WebContent"/>
+ <classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.WebProject">
+ <attributes>
+ <attribute name="hide" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.baseBrowserLibrary"/>
+ <classpathentry kind="output" path=""/>
+</classpath>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.jdt.core.prefs 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,7 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
+org.eclipse.jdt.core.compiler.compliance=1.6
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.source=1.6
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.component
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.component (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.component 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
+ <wb-module deploy-name="app2">
+ <wb-resource deploy-path="/" source-path="/WebContent" tag="defaultRootSource"/>
+ <wb-resource deploy-path="/WEB-INF/classes" source-path="/src"/>
+ <property name="context-root" value="app2"/>
+ <property name="java-output-path" value="/app2/build/classes"/>
+ </wb-module>
+</project-modules>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.project.facet.core.xml
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.project.facet.core.xml (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.common.project.facet.core.xml 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<faceted-project>
+ <runtime name="JBoss 7.1.0 Runtime "/>
+ <fixed facet="wst.jsdt.web"/>
+ <fixed facet="jst.web"/>
+ <fixed facet="java"/>
+ <installed facet="java" version="1.6"/>
+ <installed facet="jst.web" version="3.0"/>
+ <installed facet="wst.jsdt.web" version="1.0"/>
+</faceted-project>
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.container
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.container (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.container 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1 @@
+org.eclipse.wst.jsdt.launching.baseBrowserLibrary
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.name
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.name (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/.settings/org.eclipse.wst.jsdt.ui.superType.name 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1 @@
+Window
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/META-INF/MANIFEST.MF
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/META-INF/MANIFEST.MF (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/META-INF/MANIFEST.MF 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path:
+
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/WEB-INF/web.xml
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/WEB-INF/web.xml (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/WebContent/WEB-INF/web.xml 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" version="3.0">
+ <display-name>app2</display-name>
+
+ <servlet-mapping>
+ <servlet-name>javax.ws.core.Application</servlet-name>
+ <url-pattern>/path/*</url-pattern>
+ </servlet-mapping>
+
+</web-app>
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/App.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/App.java (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/App.java 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,19 @@
+package test;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.ws.rs.ApplicationPath;
+import javax.ws.rs.core.Application;
+
+@ApplicationPath("/path")
+public class App extends Application {
+
+ @Override
+ public Set<Class<?>> getClasses() {
+ Set<Class<?>> classes = new HashSet<Class<?>>();
+ classes.add(RestService.class);
+ return super.getClasses();
+ }
+
+}
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/RestService.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/RestService.java (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/app2/src/test/RestService.java 2012-06-07 15:38:28 UTC (rev 41774)
@@ -0,0 +1,14 @@
+package test;
+
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+
+@Path("/rest")
+public class RestService {
+
+ @GET
+ public void method() {
+
+ }
+
+}
13 years, 4 months
JBoss Tools SVN: r41773 - trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/editor.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-06-07 11:34:57 -0400 (Thu, 07 Jun 2012)
New Revision: 41773
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/editor/BeansEditor.java
Log:
fixing index number to correctly determine which tree should be used
Modified: trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/editor/BeansEditor.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/editor/BeansEditor.java 2012-06-07 15:34:39 UTC (rev 41772)
+++ trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/editor/BeansEditor.java 2012-06-07 15:34:57 UTC (rev 41773)
@@ -73,7 +73,7 @@
}
private BeansEditor modify(Item item, String name, String actionLabel, DialogHandler h) {
- SWTBotTree tree = bot.tree(1);
+ SWTBotTree tree = bot.tree(2);
for (SWTBotTreeItem ti:tree.getAllItems()) {
log.setLevel(Level.FATAL);
log.fatal(ti.getText());
13 years, 4 months
JBoss Tools SVN: r41772 - branches/jbosstools-3.3.x/build.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2012-06-07 11:34:39 -0400 (Thu, 07 Jun 2012)
New Revision: 41772
Modified:
branches/jbosstools-3.3.x/build/publish.sh
Log:
fix pointer to new build/publish/publish.sh script
Modified: branches/jbosstools-3.3.x/build/publish.sh
===================================================================
--- branches/jbosstools-3.3.x/build/publish.sh 2012-06-07 15:30:53 UTC (rev 41771)
+++ branches/jbosstools-3.3.x/build/publish.sh 2012-06-07 15:34:39 UTC (rev 41772)
@@ -1,2 +1,3 @@
#!/bin/bash
-./publish/publish.sh
+cd `pwd`/publish
+./publish.sh
13 years, 4 months
JBoss Tools SVN: r41771 - in trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test: wizard and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-06-07 11:30:53 -0400 (Thu, 07 Jun 2012)
New Revision: 41771
Removed:
trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/NodeContextUtil.java
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/CDIProjectHelper.java
trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/QuickFixHelper.java
trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/wizard/PerspectiveTest.java
Log:
replacing NodeContextUtil class with ContextHelper from ui.bot.ext
Modified: trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/CDIProjectHelper.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/CDIProjectHelper.java 2012-06-07 13:45:32 UTC (rev 41770)
+++ trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/CDIProjectHelper.java 2012-06-07 15:30:53 UTC (rev 41771)
@@ -156,8 +156,11 @@
SWTBotTree tree = projectExplorer.bot().tree();
SWTBotTreeItem item = tree.getTreeItem(projectName);
item.expand();
- NodeContextUtil.nodeContextMenu(tree, item, CDIConstants.CONFIGURE,
- CDIConstants.ADD_CDI_SUPPORT).click();
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(
+ ContextMenuHelper.getContextMenu(
+ tree, IDELabel.Menu.PACKAGE_EXPLORER_CONFIGURE, false));
+ menu.menu(CDIConstants.ADD_CDI_SUPPORT).click();
bot.button(IDELabel.Button.OK).click();
bot.waitWhile(new ProgressInformationShellIsActiveCondition(), TaskDuration.LONG.getTimeout());
}
Deleted: trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/NodeContextUtil.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/NodeContextUtil.java 2012-06-07 13:45:32 UTC (rev 41770)
+++ trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/NodeContextUtil.java 2012-06-07 15:30:53 UTC (rev 41771)
@@ -1,44 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2010 Red Hat, Inc.
- * Distributed under license by Red Hat, Inc. All rights reserved.
- * This program is made available under the terms of the
- * Eclipse Public License v1.0 which accompanies this distribution,
- * and is available at http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Red Hat, Inc. - initial API and implementation
- ******************************************************************************/
-
-package org.jboss.tools.cdi.bot.test.uiutils;
-
-import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
-import org.eclipse.swtbot.swt.finder.results.Result;
-import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu;
-import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree;
-import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
-import org.jboss.tools.ui.bot.ext.helper.ContextMenuHelper;
-
-public class NodeContextUtil {
-
- private NodeContextUtil() {
- throw new AssertionError();
- }
-
- public static SWTBotMenu nodeContextMenu(final SWTBotTree tree,
- SWTBotTreeItem item, final String... menu) {
- assert menu.length > 0;
- ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
- return UIThreadRunnable.syncExec(new Result<SWTBotMenu>() {
-
- public SWTBotMenu run() {
- SWTBotMenu m = new SWTBotMenu(ContextMenuHelper.getContextMenu(
- tree, menu[0], false));
- for (int i = 1; i < menu.length; i++) {
- m = m.menu(menu[i]);
- }
- return m;
- }
- });
- }
-
-}
Modified: trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/QuickFixHelper.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/QuickFixHelper.java 2012-06-07 13:45:32 UTC (rev 41770)
+++ trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/uiutils/QuickFixHelper.java 2012-06-07 15:30:53 UTC (rev 41771)
@@ -10,6 +10,8 @@
******************************************************************************/
package org.jboss.tools.cdi.bot.test.uiutils;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
import org.jboss.tools.cdi.bot.test.CDIConstants;
import org.jboss.tools.cdi.bot.test.CDITestBase;
@@ -18,6 +20,7 @@
import org.jboss.tools.ui.bot.ext.SWTEclipseExt;
import org.jboss.tools.ui.bot.ext.SWTJBTExt;
import org.jboss.tools.ui.bot.ext.Timing;
+import org.jboss.tools.ui.bot.ext.helper.ContextMenuHelper;
import org.jboss.tools.ui.bot.ext.types.IDELabel;
import org.jboss.tools.ui.bot.ext.types.ViewType;
import org.jboss.tools.ui.bot.ext.view.ProblemsView;
@@ -45,7 +48,12 @@
* @param item
*/
public void openQuickFix(SWTBotTreeItem item) {
- NodeContextUtil.nodeContextMenu(bot.tree(), item, CDIConstants.QUICK_FIX).click();
+ SWTBotTree problemsTree = bot.viewByTitle(
+ ViewType.PROBLEMS.getViewLabel()).bot().tree();
+ ContextMenuHelper.prepareTreeItemForContextMenu(
+ problemsTree, item);
+ new SWTBotMenu(ContextMenuHelper.getContextMenu(problemsTree,
+ CDIConstants.QUICK_FIX, false)).click();
}
/**
Modified: trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/wizard/PerspectiveTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/wizard/PerspectiveTest.java 2012-06-07 13:45:32 UTC (rev 41770)
+++ trunk/cdi/tests/org.jboss.tools.cdi.bot.test/src/org/jboss/tools/cdi/bot/test/wizard/PerspectiveTest.java 2012-06-07 15:30:53 UTC (rev 41771)
@@ -13,14 +13,16 @@
import org.eclipse.swt.SWTException;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
import org.jboss.tools.cdi.bot.test.CDIAllBotTests;
import org.jboss.tools.cdi.bot.test.CDISmokeBotTests;
import org.jboss.tools.cdi.bot.test.CDITestBase;
import org.jboss.tools.cdi.bot.test.annotations.CDIWizardType;
-import org.jboss.tools.cdi.bot.test.uiutils.NodeContextUtil;
import org.jboss.tools.ui.bot.ext.Timing;
+import org.jboss.tools.ui.bot.ext.helper.ContextMenuHelper;
+import org.jboss.tools.ui.bot.ext.types.IDELabel;
import org.jboss.tools.ui.bot.ext.types.PerspectiveType;
import org.junit.Test;
import org.junit.runners.Suite.SuiteClasses;
@@ -98,9 +100,13 @@
item.expand();
boolean artifactWizardExists = true;
try {
- NodeContextUtil.nodeContextMenu(tree, item, "New", wizardType.getAnnotationType()).click();
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(
+ ContextMenuHelper.getContextMenu(
+ tree, IDELabel.Menu.NEW, false));
+ menu.menu(wizardType.getAnnotationType()).click();
bot.sleep(Timing.time500MS());
- bot.activeShell().bot().button("Cancel").click();
+ bot.activeShell().bot().button(IDELabel.Button.CANCEL).click();
} catch (SWTException exc) {
artifactWizardExists = false;
13 years, 4 months