JBoss Tools SVN: r44530 - trunk/build/parent.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2012-10-16 13:52:09 -0400 (Tue, 16 Oct 2012)
New Revision: 44530
Modified:
trunk/build/parent/pom.xml
Log:
add https://repository.jboss.org/nexus/content/repositories/snapshots/ as a repository from which to resolve stuff (fix for brno jenkins servers?)
Modified: trunk/build/parent/pom.xml
===================================================================
--- trunk/build/parent/pom.xml 2012-10-16 15:11:31 UTC (rev 44529)
+++ trunk/build/parent/pom.xml 2012-10-16 17:52:09 UTC (rev 44530)
@@ -761,6 +761,14 @@
<enabled>true</enabled>
</releases>
</repository>
+ <repository>
+ <id>jboss-snapshots-repository</id>
+ <name>JBoss Snapshots Repository</name>
+ <url>https://repository.jboss.org/nexus/content/repositories/snapshots/</url>
+ <snapshots>
+ <enabled>true</enabled>
+ </snapshots>
+ </repository>
</repositories>
<!-- Additional m2 repos to resolve things like org.eclipse.tycho:tycho-maven-plugin:0.16.0-SNAPSHOT -->
12 years, 4 months
JBoss Tools SVN: r44529 - in trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test: rest and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-10-16 11:11:31 -0400 (Tue, 16 Oct 2012)
New Revision: 44529
Modified:
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/annotation/HTTPMethodAnnotationQuickFixTest.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/validation/JaxRsValidatorTest.java
Log:
new test implemented
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/annotation/HTTPMethodAnnotationQuickFixTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/annotation/HTTPMethodAnnotationQuickFixTest.java 2012-10-16 15:10:56 UTC (rev 44528)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/annotation/HTTPMethodAnnotationQuickFixTest.java 2012-10-16 15:11:31 UTC (rev 44529)
@@ -6,6 +6,7 @@
import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEclipseEditor;
import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotEditor;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
+import org.jboss.tools.ui.bot.ext.Timing;
import org.jboss.tools.ui.bot.ext.config.Annotations.Require;
import org.jboss.tools.ui.bot.ext.config.Annotations.Server;
import org.jboss.tools.ui.bot.ext.config.Annotations.ServerState;
@@ -24,13 +25,8 @@
public class HTTPMethodAnnotationQuickFixTest extends WSTestBase {
@Override
- protected String getWsProjectName() {
- return "httpAnnot";
- }
-
- @Override
public void setup() {
- importWSTestProject(getWsProjectName());
+
}
@Override
@@ -39,21 +35,53 @@
}
@Test
- public void testQuickFixes() {
+ public void testHTTPMethodWithoutParameters() {
+ /* import the project */
+ String wsProjectName = "httpAnnot1";
+ importWSTestProject(wsProjectName);
- /* workaround for JBIDE-12690
- jbide12680Workaround(getWsProjectName(), "src", "test", "MyAnnot.java"); */
+ /* workaround for JBIDE-12690 */
+ jbide12680Workaround(wsProjectName, "src", "test", "MyAnnot.java");
+ /* assert that there is one Java problem */
+ assertThat(errorsByType("Java Problem").length, equalTo(1));
+
+ /* get quickfix bot for HttpMethod annotation */
+ QuickFixBot qBot = quickFixBot("@HttpMethod");
+
+ /* check that there are quick fixes for both required annotations */
+ qBot.checkQuickFix("Add missing attributes", true);
+ bot.activeEditor().save();
+
+ /* assert that there is one JAX-RS errors - empty value */
+ assertThat(errorsByType("JAX-RS Problem").length, equalTo(1));
+ }
+
+ @Test
+ public void testTargetRetentionQuickFixes() {
+
+ /* import the project */
+ String wsProjectName = "httpAnnot2";
+ importWSTestProject(wsProjectName);
+
+ /* workaround for JBIDE-12690 */
+ jbide12680Workaround(wsProjectName, "src", "test", "MyAnnot.java");
+
/* assert that there are two JAX-RS errors */
assertThat(errorsByType("JAX-RS Problem").length, equalTo(2));
/* get quickfix bot for MyAnnot annotation */
- QuickFixBot bot = quickFixBot();
+ QuickFixBot qBot = quickFixBot("MyAnnot");
/* check that there are quick fixes for both required annotations */
- bot.checkQuickFix("Add @Target annotation on type MyAnnot", false);
- bot.checkQuickFix("Add @Retention annotation on type MyAnnot", false);
+ qBot.checkQuickFix("Add @Target annotation on type MyAnnot", true);
+ /* there is need to wait a while until validation starts to work */
+ bot.sleep(Timing.time2S());
+ qBot.checkQuickFix("Add @Retention annotation on type MyAnnot", true);
+ bot.sleep(Timing.time2S());
+ /* assert that there are no JAX-RS errors */
+ assertThat(errorsByType("JAX-RS Problem").length, equalTo(0));
}
private void jbide12680Workaround(String projectName, String... path) {
@@ -63,12 +91,12 @@
eclipseEditor.save();
}
- private QuickFixBot quickFixBot() {
+ private QuickFixBot quickFixBot(String underlinedText) {
SWTBotEditorExt editor = new SWTBotEditorExt(bot.activeEditor().getReference(), bot);
SWTBotEclipseEditor eclipseEditor = editor.toTextEditor();
int lineIndex = 0;
for (String line : eclipseEditor.getLines()) {
- if (line.contains("@Http")) {
+ if (line.contains(underlinedText)) {
break;
}
lineIndex++;
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-10-16 15:10:56 UTC (rev 44528)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/RESTfulHelper.java 2012-10-16 15:11:31 UTC (rev 44529)
@@ -44,7 +44,7 @@
private static final ResourceHelper resourceHelper = new ResourceHelper();
private static final String PATH_PARAM_VALID_ERROR = "@PathParam value";
- private static final String VALIDATION_SETTINGS_CHANGED = "Validation Settings Changed";
+ private static final String VALIDATOR_SETTINGS_CHANGED = "Validator Settings Changed";
private enum ConfigureOption {
ENABLE, DISABLE;
@@ -84,7 +84,7 @@
validationBot.checkBox(0).deselect();
}
validationBot.button(IDELabel.Button.OK).click();
- if (bot.activeShell().getText().equals(VALIDATION_SETTINGS_CHANGED)) {
+ if (bot.activeShell().getText().equals(VALIDATOR_SETTINGS_CHANGED)) {
bot.activeShell().bot().button(IDELabel.Button.YES).click();
}
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/JaxRsValidatorTest.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/JaxRsValidatorTest.java 2012-10-16 15:10:56 UTC (rev 44528)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/src/org/jboss/tools/ws/ui/bot/test/rest/validation/JaxRsValidatorTest.java 2012-10-16 15:11:31 UTC (rev 44529)
@@ -56,6 +56,9 @@
/* test count of validation errors */
assertCountOfPathAnnotationValidationErrors(getWsProjectName(), 0);
+
+ /* enable restful validation - to have proper test environment*/
+ restfulHelper.enableRESTValidation();
}
private SWTBot openJaxRsValidator() {
12 years, 4 months
JBoss Tools SVN: r44528 - trunk/ws/tests/org.jboss.tools.ws.ui.bot.test.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-10-16 11:10:56 -0400 (Tue, 16 Oct 2012)
New Revision: 44528
Modified:
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/pom.xml
Log:
added eclipse.jdt.feature dependency to be able to set default jdk on mac
Modified: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/pom.xml
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/pom.xml 2012-10-16 15:08:33 UTC (rev 44527)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/pom.xml 2012-10-16 15:10:56 UTC (rev 44528)
@@ -77,6 +77,12 @@
<artifactId>org.jboss.ide.eclipse.as.feature.feature.group</artifactId>
<version>0.0.0</version>
</dependency>
+ <!-- This entry should enable creating of default JDK on Mac -->
+ <dependency>
+ <type>p2-installable-unit</type>
+ <artifactId>org.eclipse.jdt.feature.group</artifactId>
+ <version>0.0.0</version>
+ </dependency>
</dependencies>
</configuration>
</plugin>
12 years, 4 months
JBoss Tools SVN: r44527 - in trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects: httpAnnot1 and 13 other directories.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-10-16 11:08:33 -0400 (Tue, 16 Oct 2012)
New Revision: 44527
Added:
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.classpath
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.project
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/.jsdtscope
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.common.component
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.common.project.facet.core.xml
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.container
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.name
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.jboss.ide.eclipse.as.core.prefs
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/META-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/META-INF/MANIFEST.MF
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/WEB-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/WEB-INF/lib/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/build/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/src/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/src/test/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/src/test/MyAnnot.java
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.classpath
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.project
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/.jsdtscope
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.common.component
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.common.project.facet.core.xml
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.container
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.name
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.jboss.ide.eclipse.as.core.prefs
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/META-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/META-INF/MANIFEST.MF
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/WEB-INF/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/WEB-INF/lib/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/build/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/src/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/src/test/
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/src/test/MyAnnot.java
Removed:
trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot/
Log:
new test projects added
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.classpath
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.classpath
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.project
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.project
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/.jsdtscope
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/.jsdtscope
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.common.component
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.common.component
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.common.project.facet.core.xml
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.common.project.facet.core.xml
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.container
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.container (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.container 2012-10-16 15:08:33 UTC (rev 44527)
@@ -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/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.name
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.name (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.eclipse.wst.jsdt.ui.superType.name 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1 @@
+Window
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.jboss.ide.eclipse.as.core.prefs
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.jboss.ide.eclipse.as.core.prefs (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/.settings/org.jboss.ide.eclipse.as.core.prefs 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+org.jboss.ide.eclipse.as.core.singledeployable.deployableList=
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/META-INF/MANIFEST.MF
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/META-INF/MANIFEST.MF (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/WebContent/META-INF/MANIFEST.MF 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path:
+
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/src/test/MyAnnot.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/src/test/MyAnnot.java (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot1/src/test/MyAnnot.java 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1,14 @@
+package test;
+
+import javax.ws.rs.HttpMethod;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+import java.lang.annotation.ElementType;
+
+(a)Target(ElementType.METHOD)
+(a)Retention(RetentionPolicy.RUNTIME)
+@HttpMethod
+public @interface MyAnnot {
+
+}
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.classpath
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.classpath
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.project
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.project
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/.jsdtscope
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/.jsdtscope
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.common.component
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.common.component
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.common.project.facet.core.xml
===================================================================
(Binary files differ)
Property changes on: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.common.project.facet.core.xml
___________________________________________________________________
Added: svn:mime-type
+ application/xml
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.container
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.container (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.container 2012-10-16 15:08:33 UTC (rev 44527)
@@ -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/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.name
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.name (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.eclipse.wst.jsdt.ui.superType.name 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1 @@
+Window
\ No newline at end of file
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.jboss.ide.eclipse.as.core.prefs
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.jboss.ide.eclipse.as.core.prefs (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/.settings/org.jboss.ide.eclipse.as.core.prefs 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+org.jboss.ide.eclipse.as.core.singledeployable.deployableList=
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/META-INF/MANIFEST.MF
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/META-INF/MANIFEST.MF (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/WebContent/META-INF/MANIFEST.MF 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path:
+
Added: trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/src/test/MyAnnot.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/src/test/MyAnnot.java (rev 0)
+++ trunk/ws/tests/org.jboss.tools.ws.ui.bot.test/resources/projects/httpAnnot2/src/test/MyAnnot.java 2012-10-16 15:08:33 UTC (rev 44527)
@@ -0,0 +1,8 @@
+package test;
+
+import javax.ws.rs.HttpMethod;
+
+@HttpMethod(value = "METHOD")
+public @interface MyAnnot {
+
+}
12 years, 4 months
JBoss Tools SVN: r44526 - in workspace/snjeza/org.jboss.tools.arquillian.updatesite: features and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: snjeza
Date: 2012-10-16 10:46:38 -0400 (Tue, 16 Oct 2012)
New Revision: 44526
Added:
workspace/snjeza/org.jboss.tools.arquillian.updatesite/features/org.jboss.tools.arquillian.feature_1.0.2.201210161645.jar
workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.core_1.0.2.201210161645.jar
workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.ui_1.0.2.201210161645.jar
Removed:
workspace/snjeza/org.jboss.tools.arquillian.updatesite/features/org.jboss.tools.arquillian.feature_1.0.2.201210151923.jar
workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.core_1.0.2.201210151923.jar
workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.ui_1.0.2.201210151923.jar
Modified:
workspace/snjeza/org.jboss.tools.arquillian.updatesite/artifacts.jar
workspace/snjeza/org.jboss.tools.arquillian.updatesite/content.jar
workspace/snjeza/org.jboss.tools.arquillian.updatesite/site.xml
Log:
Adding the Arquillian validator
Modified: workspace/snjeza/org.jboss.tools.arquillian.updatesite/artifacts.jar
===================================================================
(Binary files differ)
Modified: workspace/snjeza/org.jboss.tools.arquillian.updatesite/content.jar
===================================================================
(Binary files differ)
Deleted: workspace/snjeza/org.jboss.tools.arquillian.updatesite/features/org.jboss.tools.arquillian.feature_1.0.2.201210151923.jar
===================================================================
(Binary files differ)
Added: workspace/snjeza/org.jboss.tools.arquillian.updatesite/features/org.jboss.tools.arquillian.feature_1.0.2.201210161645.jar
===================================================================
(Binary files differ)
Property changes on: workspace/snjeza/org.jboss.tools.arquillian.updatesite/features/org.jboss.tools.arquillian.feature_1.0.2.201210161645.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Deleted: workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.core_1.0.2.201210151923.jar
===================================================================
(Binary files differ)
Added: workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.core_1.0.2.201210161645.jar
===================================================================
(Binary files differ)
Property changes on: workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.core_1.0.2.201210161645.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Deleted: workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.ui_1.0.2.201210151923.jar
===================================================================
(Binary files differ)
Added: workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.ui_1.0.2.201210161645.jar
===================================================================
(Binary files differ)
Property changes on: workspace/snjeza/org.jboss.tools.arquillian.updatesite/plugins/org.jboss.tools.arquillian.ui_1.0.2.201210161645.jar
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: workspace/snjeza/org.jboss.tools.arquillian.updatesite/site.xml
===================================================================
--- workspace/snjeza/org.jboss.tools.arquillian.updatesite/site.xml 2012-10-16 13:48:21 UTC (rev 44525)
+++ workspace/snjeza/org.jboss.tools.arquillian.updatesite/site.xml 2012-10-16 14:46:38 UTC (rev 44526)
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<site>
- <feature url="features/org.jboss.tools.arquillian.feature_1.0.2.201210151923.jar" id="org.jboss.tools.arquillian.feature" version="1.0.2.201210151923">
+ <feature url="features/org.jboss.tools.arquillian.feature_1.0.2.201210161645.jar" id="org.jboss.tools.arquillian.feature" version="1.0.2.201210161645">
<category name="org.jboss.tools.arquillian"/>
</feature>
<category-def name="org.jboss.tools.arquillian" label="Arquillian Support"/>
12 years, 4 months
JBoss Tools SVN: r44525 - in trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test: META-INF and 3 other directories.
by jbosstools-commits@lists.jboss.org
Author: sbunciak
Date: 2012-10-16 09:48:21 -0400 (Tue, 16 Oct 2012)
New Revision: 44525
Modified:
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/META-INF/MANIFEST.MF
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTests.launch
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTestsMaven.launch
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/resources/openshift.ui.bot.test.properties
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/OpenShiftJenkinsBotTests.java
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/Connection.java
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/CreateDomain.java
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/DeleteDomain.java
trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/RenameDomain.java
Log:
Added 3 cases to automated Jenkins suite compatible with JBT 4.0.0.Beta1
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/META-INF/MANIFEST.MF
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/META-INF/MANIFEST.MF 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/META-INF/MANIFEST.MF 2012-10-16 13:48:21 UTC (rev 44525)
@@ -8,7 +8,7 @@
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
org.apache.log4j;bundle-version="1.2.15",
- org.jboss.tools.ui.bot.ext,
+ org.jboss.tools.ui.bot.ext;bundle-version="3.4.0",
org.junit;bundle-version="4.8.1",
org.eclipse.swtbot.eclipse.core;bundle-version="2.0.5",
org.eclipse.swtbot.eclipse.finder;bundle-version="2.0.5",
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTests.launch
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTests.launch 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTests.launch 2012-10-16 13:48:21 UTC (rev 44525)
@@ -14,7 +14,7 @@
<booleanAttribute key="includeOptional" value="true"/>
<stringAttribute key="location" value="${workspace_loc}/../junit-workspace"/>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
-<listEntry value="/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/OpenShiftAllBotTests.java"/>
+<listEntry value="/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/OpenShiftJenkinsBotTests.java"/>
</listAttribute>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
<listEntry value="1"/>
@@ -27,7 +27,7 @@
<stringAttribute key="org.eclipse.jdt.junit.TESTNAME" value=""/>
<stringAttribute key="org.eclipse.jdt.junit.TEST_KIND" value="org.eclipse.jdt.junit.loader.junit4"/>
<stringAttribute key="org.eclipse.jdt.launching.JRE_CONTAINER" value="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
-<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.jboss.tools.openshift.ui.bot.test.OpenShiftAllBotTests"/>
+<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.jboss.tools.openshift.ui.bot.test.OpenShiftJenkinsBotTests"/>
<stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-os ${target.os} -ws ${target.ws} -arch ${target.arch} -nl ${target.nl} -consoleLog"/>
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.jboss.tools.openshift.ui.bot.test"/>
<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.pde.ui.workbenchClasspathProvider"/>
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTestsMaven.launch
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTestsMaven.launch 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/OpenShiftBotTestsMaven.launch 2012-10-16 13:48:21 UTC (rev 44525)
@@ -4,7 +4,7 @@
<stringAttribute key="M2_GOALS" value="clean install"/>
<booleanAttribute key="M2_NON_RECURSIVE" value="false"/>
<booleanAttribute key="M2_OFFLINE" value="false"/>
-<stringAttribute key="M2_PROFILES" value="default"/>
+<stringAttribute key="M2_PROFILES" value="maximum.target,jbosstools-staging-aggregate"/>
<listAttribute key="M2_PROPERTIES">
<listEntry value="swtbot.test.skip=false"/>
<listEntry value="configurations.dir=${project_loc}/resources"/>
@@ -17,5 +17,5 @@
<mapAttribute key="org.eclipse.debug.core.environmentVariables">
<mapEntry key="DISPLAY" value=":${string_prompt}"/>
</mapAttribute>
-<stringAttribute key="org.eclipse.jdt.launching.WORKING_DIRECTORY" value="${workspace_loc:/org.jboss.tools.openshift.ui.bot.test}"/>
+<stringAttribute key="org.eclipse.jdt.launching.WORKING_DIRECTORY" value="${workspace_loc:/openshift/tests/org.jboss.tools.openshift.ui.bot.test}"/>
</launchConfiguration>
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/resources/openshift.ui.bot.test.properties
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/resources/openshift.ui.bot.test.properties 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/resources/openshift.ui.bot.test.properties 2012-10-16 13:48:21 UTC (rev 44525)
@@ -5,3 +5,5 @@
openshift.user.wrongpwd=rhtest
openshift.domain=rhtestdomain
openshift.domain.new=rhtest
+openshift.server.prod=openshift.redhat.com
+openshift.server.stg=stg.openshift.redhat.com
\ No newline at end of file
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/OpenShiftJenkinsBotTests.java
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/OpenShiftJenkinsBotTests.java 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/OpenShiftJenkinsBotTests.java 2012-10-16 13:48:21 UTC (rev 44525)
@@ -1,12 +1,18 @@
package org.jboss.tools.openshift.ui.bot.test;
import org.jboss.tools.openshift.ui.bot.test.explorer.Connection;
+import org.jboss.tools.openshift.ui.bot.test.explorer.CreateDomain;
+import org.jboss.tools.openshift.ui.bot.test.explorer.DeleteDomain;
+import org.jboss.tools.openshift.ui.bot.test.explorer.RenameDomain;
import org.jboss.tools.ui.bot.ext.RequirementAwareSuite;
import org.junit.runner.RunWith;
import org.junit.runners.Suite.SuiteClasses;
@SuiteClasses({
-Connection.class
+Connection.class,
+CreateDomain.class,
+RenameDomain.class,
+DeleteDomain.class
})
@RunWith(RequirementAwareSuite.class)
public class OpenShiftJenkinsBotTests {
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/Connection.java
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/Connection.java 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/Connection.java 2012-10-16 13:48:21 UTC (rev 44525)
@@ -28,14 +28,14 @@
// set wrong user credentials
bot.text(0).setText(TestProperties.get("openshift.user.name"));
bot.text(1).setText(TestProperties.get("openshift.user.wrongpwd"));
- bot.checkBox(0).deselect();
+ bot.checkBox(1).deselect();
SWTBotButton finishButton = bot.button(IDELabel.Button.FINISH);
// try to move forward
finishButton.click();
// wait for credentials validation
- bot.waitWhile(new NonSystemJobRunsCondition(), TIME_20S);
+ bot.waitWhile(new NonSystemJobRunsCondition(), TIME_60S);
assertFalse("Finish button shouldn't be enabled.",
finishButton.isEnabled());
@@ -43,7 +43,7 @@
// set correct user credentials and save it to secure storage
bot.text(0).setText(TestProperties.get("openshift.user.name"));
bot.text(1).setText(TestProperties.get("openshift.user.pwd"));
-
+ bot.checkBox(1).deselect();
// create connection to OpenShift account
finishButton.click();
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/CreateDomain.java
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/CreateDomain.java 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/CreateDomain.java 2012-10-16 13:48:21 UTC (rev 44525)
@@ -1,8 +1,5 @@
package org.jboss.tools.openshift.ui.bot.test.explorer;
-import java.io.File;
-import java.util.Date;
-
import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
import org.eclipse.swtbot.swt.finder.waits.Conditions;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotButton;
@@ -12,7 +9,6 @@
import org.jboss.tools.ui.bot.ext.SWTTestExt;
import org.jboss.tools.ui.bot.ext.condition.NonSystemJobRunsCondition;
import org.jboss.tools.ui.bot.ext.types.IDELabel;
-import org.junit.Before;
import org.junit.Test;
/**
@@ -24,34 +20,18 @@
*/
public class CreateDomain extends SWTTestExt {
- private boolean keyAvailable = false;
-
- @Before
- public void prepareSSHPrefs() {
- // clear dir from libra stuff so wizard can create new
- File sshDir = new File(System.getProperty("user.home") + "/.ssh");
-
- if (sshDir.exists() && sshDir.isDirectory()
- && sshDir.listFiles().length > 0) {
- for (File file : sshDir.listFiles()) {
- if (file.getName().contains("id_rsa"))
- //keyAvailable = true;
- file.delete();
- if (file.getName().contains("known_hosts"))
- file.delete();
- }
- }
-
- }
-
@Test
public void canCreateDomain() throws InterruptedException {
// open OpenShift Explorer
SWTBotView openshiftExplorer = open
.viewOpen(OpenShiftUI.Explorer.iView);
- openshiftExplorer.bot().tree()
- .getTreeItem(TestProperties.get("openshift.user.name"))
+ openshiftExplorer
+ .bot()
+ .tree()
+ .getTreeItem(
+ TestProperties.get("openshift.user.name") + " "
+ + TestProperties.get("openshift.server.prod"))
.contextMenu(OpenShiftUI.Labels.EXPLORER_CREATE_EDIT_DOMAIN)
.click();
@@ -66,39 +46,14 @@
log.info("*** OpenShift SWTBot Tests: Domain name set. ***");
SWTBotButton finishBtn = bot.button(IDELabel.Button.FINISH);
-
-
- bot.link(0).click();
-
- if (keyAvailable) {
-// TODO: add them to the list
- bot.waitForShell(OpenShiftUI.Shell.SSH_WIZARD);
- assertTrue("SSH key should be set!", bot.table().columnCount() > 0);
- } else {
-
- bot.waitForShell(OpenShiftUI.Shell.SSH_WIZARD);
- bot.buttonInGroup("New...", "SSH Public Keys").click();
- bot.waitForShell(OpenShiftUI.Shell.NEW_SSH);
-
- bot.textInGroup("New SSH Key", 0).setText("jbtkey" + new Date());
- bot.textInGroup("New SSH Key", 2).setText("id_rsa");
- bot.button(IDELabel.Button.FINISH).click();
-
- bot.waitWhile(new NonSystemJobRunsCondition(), TIME_20S, TIME_1S);
- bot.waitForShell(OpenShiftUI.Shell.SSH_WIZARD);
-
- bot.button(IDELabel.Button.OK).click();
- bot.waitForShell(OpenShiftUI.Shell.CREATE_DOMAIN);
-
- log.info("*** OpenShift SWTBot Tests: SSH Keys created. ***");
- }
-
bot.waitUntil(Conditions.widgetIsEnabled(finishBtn));
finishBtn.click();
// wait while the domain is being created
- bot.waitUntil(Conditions.shellCloses(bot.activeShell()), TIME_60S);
+ bot.waitUntil(Conditions.shellCloses(bot.activeShell()), TIME_60S * 3,
+ TIME_1S);
+ bot.waitWhile(new NonSystemJobRunsCondition(), TIME_20S, TIME_1S);
log.info("*** OpenShift SWTBot Tests: Domain created. ***");
}
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/DeleteDomain.java
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/DeleteDomain.java 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/DeleteDomain.java 2012-10-16 13:48:21 UTC (rev 44525)
@@ -16,19 +16,23 @@
// refresh first
explorer.bot().tree()
- .getTreeItem(TestProperties.get("openshift.user.name"))
+ .getTreeItem(
+ TestProperties.get("openshift.user.name") + " "
+ + TestProperties.get("openshift.server.prod"))
.contextMenu(OpenShiftUI.Labels.REFRESH).click();
bot.waitWhile(new NonSystemJobRunsCondition(), TIME_60S * 3, TIME_1S);
// delete
explorer.bot().tree()
- .getTreeItem(TestProperties.get("openshift.user.name"))
+ .getTreeItem(
+ TestProperties.get("openshift.user.name") + " "
+ + TestProperties.get("openshift.server.prod"))
.contextMenu(OpenShiftUI.Labels.EXPLORER_DELETE_DOMAIN).click();
bot.checkBox().select();
bot.button("OK").click();
- bot.waitWhile(new NonSystemJobRunsCondition(), TIME_60S * 3, TIME_1S);
+ bot.waitWhile(new NonSystemJobRunsCondition(), TIME_60S * 4, TIME_1S);
}
}
Modified: trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/RenameDomain.java
===================================================================
--- trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/RenameDomain.java 2012-10-16 12:29:30 UTC (rev 44524)
+++ trunk/openshift/tests/org.jboss.tools.openshift.ui.bot.test/src/org/jboss/tools/openshift/ui/bot/test/explorer/RenameDomain.java 2012-10-16 13:48:21 UTC (rev 44525)
@@ -6,6 +6,7 @@
import org.jboss.tools.openshift.ui.bot.util.OpenShiftUI;
import org.jboss.tools.openshift.ui.bot.util.TestProperties;
import org.jboss.tools.ui.bot.ext.SWTTestExt;
+import org.jboss.tools.ui.bot.ext.condition.NonSystemJobRunsCondition;
import org.jboss.tools.ui.bot.ext.types.IDELabel;
import org.junit.Test;
@@ -17,11 +18,13 @@
SWTBotView explorer = open.viewOpen(OpenShiftUI.Explorer.iView);
explorer.bot().tree()
- .getTreeItem(TestProperties.get("openshift.user.name"))
+ .getTreeItem(
+ TestProperties.get("openshift.user.name") + " "
+ + TestProperties.get("openshift.server.prod"))
.contextMenu(OpenShiftUI.Labels.EXPLORER_CREATE_EDIT_DOMAIN)
.click();
- bot.waitForShell("");
+ bot.waitForShell(OpenShiftUI.Shell.EDIT_DOMAIN);
SWTBotText domainText = bot.text(0);
@@ -32,9 +35,14 @@
domainText.setText(TestProperties.get("openshift.domain.new"));
+ log.info("*** OpenShift SWTBot Tests: Domain name re-set. ***");
+
bot.button(IDELabel.Button.FINISH).click();
bot.waitUntil(Conditions.shellCloses(bot.activeShell()), TIME_60S + TIME_30S);
-
+
+ log.info("*** OpenShift SWTBot Tests: Domain renamed. ***");
+
+ bot.waitWhile(new NonSystemJobRunsCondition(), TIME_20S, TIME_1S);
}
}
12 years, 4 months
JBoss Tools SVN: r44524 - trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central.
by jbosstools-commits@lists.jboss.org
Author: snjeza
Date: 2012-10-16 08:29:30 -0400 (Tue, 16 Oct 2012)
New Revision: 44524
Modified:
trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/JBossCentralActivator.java
Log:
JBDS-2362 - Empty editor tab
Modified: trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/JBossCentralActivator.java
===================================================================
--- trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/JBossCentralActivator.java 2012-10-16 12:10:07 UTC (rev 44523)
+++ trunk/central/plugins/org.jboss.tools.central/src/org/jboss/tools/central/JBossCentralActivator.java 2012-10-16 12:29:30 UTC (rev 44524)
@@ -12,8 +12,10 @@
import java.net.MalformedURLException;
import java.net.URL;
+import java.util.ArrayList;
import java.util.Dictionary;
import java.util.Hashtable;
+import java.util.List;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.NullProgressMonitor;
@@ -30,10 +32,16 @@
import org.eclipse.swt.SWT;
import org.eclipse.swt.browser.Browser;
import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Shell;
+import org.eclipse.ui.IEditorDescriptor;
import org.eclipse.ui.IEditorInput;
import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.IEditorReference;
+import org.eclipse.ui.IEditorRegistry;
import org.eclipse.ui.IViewReference;
+import org.eclipse.ui.IWorkbench;
+import org.eclipse.ui.IWorkbenchListener;
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
@@ -42,6 +50,7 @@
import org.eclipse.ui.internal.WorkbenchWindow;
import org.eclipse.ui.internal.browser.WebBrowserPreference;
import org.eclipse.ui.internal.browser.WorkbenchBrowserSupport;
+import org.eclipse.ui.internal.registry.EditorRegistry;
import org.eclipse.ui.menus.CommandContributionItem;
import org.eclipse.ui.menus.CommandContributionItemParameter;
import org.eclipse.ui.plugin.AbstractUIPlugin;
@@ -106,6 +115,37 @@
private static JBossCentralActivator plugin;
private static Boolean isInternalWebBrowserAvailable;
+
+ private IWorkbenchListener workbenchListener = new IWorkbenchListener() {
+
+ @Override
+ public boolean preShutdown(IWorkbench workbench, boolean forced) {
+ Display.getDefault().syncExec(new Runnable() {
+
+ @Override
+ public void run() {
+ IWorkbenchPage page = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
+ IEditorReference[] references = page.getEditorReferences();
+ if (references != null) {
+ List<IEditorReference> l = new ArrayList<IEditorReference>();
+ for (IEditorReference reference:references) {
+ if (EditorRegistry.EMPTY_EDITOR_ID.equals(reference.getId()) ||
+ JBossCentralEditor.ID.equals(reference.getId())) {
+ l.add(reference);
+ }
+ }
+ if (l.size() > 0) {
+ page.closeEditors(l.toArray(new IEditorReference[0]), false);
+ }
+ }
+ }
+ });
+ return true;
+ }
+
+ @Override
+ public void postShutdown(IWorkbench workbench) {}
+ };
/**
* The constructor
@@ -124,6 +164,7 @@
super.start(context);
this.bundleContext = context;
plugin = this;
+ PlatformUI.getWorkbench().addWorkbenchListener(workbenchListener);
}
/*
@@ -140,6 +181,8 @@
plugin = null;
bundleContext = null;
super.stop(context);
+
+ PlatformUI.getWorkbench().removeWorkbenchListener(workbenchListener);
}
/**
@@ -305,7 +348,14 @@
Object newValue = event.getNewValue();
if (newValue instanceof Boolean
&& ((Boolean) newValue).booleanValue()) {
- openJBossCentralEditor(page);
+ Display.getCurrent().asyncExec(new Runnable() {
+
+ @Override
+ public void run() {
+ openJBossCentralEditor(page);
+ }
+ });
+
window.removePropertyChangeListener(this);
}
}
12 years, 4 months
JBoss Tools SVN: r44523 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper.
by jbosstools-commits@lists.jboss.org
Author: apodhrad
Date: 2012-10-16 08:10:07 -0400 (Tue, 16 Oct 2012)
New Revision: 44523
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/ImportHelper.java
Log:
Added importingProjectFromZip
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/ImportHelper.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/ImportHelper.java 2012-10-16 09:49:45 UTC (rev 44522)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/helper/ImportHelper.java 2012-10-16 12:10:07 UTC (rev 44523)
@@ -11,7 +11,9 @@
import org.eclipse.swtbot.swt.finder.widgets.SWTBotShell;
import org.jboss.tools.ui.bot.ext.SWTBotExt;
import org.jboss.tools.ui.bot.ext.SWTUtilExt;
+import org.jboss.tools.ui.bot.ext.gen.ActionItem.Import.GeneralExistingProjectsintoWorkspace;
import org.jboss.tools.ui.bot.ext.types.IDELabel;
+import org.jboss.tools.ui.bot.ext.wizards.SWTBotImportWizard;
/**
* Heper class for project imports
@@ -64,4 +66,17 @@
SWTUtilExt util = new SWTUtilExt(bot);
util.waitForNonIgnoredJobs();
}
+
+ /**
+ * Import project from a given zip location
+ * @param projectLocation
+ */
+ public static void importProjectFromZip(String projectLocation) {
+ SWTBotImportWizard wizard = new SWTBotImportWizard();
+ wizard.open(GeneralExistingProjectsintoWorkspace.LABEL);
+ wizard.bot().radio(1).click();
+ wizard.bot().text(1).setText(projectLocation);
+ wizard.bot().button(IDELabel.Button.REFRESH).click();
+ wizard.finishWithWait();
+ }
}
12 years, 4 months
JBoss Tools SVN: r44522 - trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke.
by jbosstools-commits@lists.jboss.org
Author: jgargula
Date: 2012-10-16 05:49:45 -0400 (Tue, 16 Oct 2012)
New Revision: 44522
Added:
trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageJbpmRuntime.java
Log:
Added previously forgotten test for jBPM runtime.
Added: trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageJbpmRuntime.java
===================================================================
--- trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageJbpmRuntime.java (rev 0)
+++ trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageJbpmRuntime.java 2012-10-16 09:49:45 UTC (rev 44522)
@@ -0,0 +1,50 @@
+package org.jboss.tools.drools.ui.bot.test.smoke;
+
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotTable;
+import org.jboss.tools.drools.ui.bot.test.DroolsAllBotTests;
+import org.jboss.tools.ui.bot.ext.SWTBotExt;
+import org.jboss.tools.ui.bot.ext.SWTEclipseExt;
+import org.jboss.tools.ui.bot.ext.SWTOpenExt;
+import org.jboss.tools.ui.bot.ext.SWTTestExt;
+import org.jboss.tools.ui.bot.ext.gen.ActionItem;
+import org.jboss.tools.ui.bot.ext.types.IDELabel;
+import org.junit.Test;
+
+public class ManageJbpmRuntime extends SWTTestExt {
+
+ @Test
+ public void testManageJbpmRuntime() {
+ addJbpmRuntime(DroolsAllBotTests.JBPM_RUNTIME_NAME, DroolsAllBotTests.JBPM_RUNTIME_LOCATION, true);
+ }
+
+ public void addJbpmRuntime(String runtimeName, String runtimeLocation, boolean setAsDefault) {
+ selectJbpmPreferences();
+ bot.button(IDELabel.Button.ADD).click();
+ bot.shell(IDELabel.Shell.JBPM_RUNTIME).activate();
+ bot.textWithLabel(IDELabel.JbpmRuntimeDialog.NAME).setText(runtimeName);
+ bot.textWithLabel(IDELabel.JbpmRuntimeDialog.PATH).setText(runtimeLocation);
+ bot.button(IDELabel.Button.OK).click();
+ bot.shell(IDELabel.Shell.PREFERENCES).activate();
+ SWTBotTable table = bot.table();
+ boolean jbpmRuntimeAdded = SWTEclipseExt.isItemInTableColumn(table, runtimeName, 0)
+ && SWTEclipseExt.isItemInTableColumn(table, runtimeLocation, 1);
+ // Set new runtime as default
+ if (setAsDefault) {
+ table.getTableItem(0).check();
+ }
+ bot.button(IDELabel.Button.OK).click();
+ assertTrue("jBPM Runtime with name [" + runtimeName + "] and location ["
+ + runtimeLocation + "] was not added properly.", jbpmRuntimeAdded);
+ DroolsAllBotTests.setTestJbpmRuntimeName(runtimeName);
+ DroolsAllBotTests.setTestJbpmRuntimeLocation(runtimeLocation);
+ SWTEclipseExt.hideWarningIfDisplayed(bot);
+ }
+
+ /**
+ * Selects Drools Preferences within Preferences Dialog
+ */
+ private void selectJbpmPreferences() {
+ jbt.delay();
+ new SWTOpenExt(new SWTBotExt()).preferenceOpen(ActionItem.Preference.JbpmInstalledJbpmRuntimes.LABEL);
+ }
+}
12 years, 4 months
JBoss Tools SVN: r44521 - in trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test: src/org/jboss/tools/drools/ui/bot/test and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: jgargula
Date: 2012-10-16 05:47:12 -0400 (Tue, 16 Oct 2012)
New Revision: 44521
Modified:
trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/resources/project.properties
trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/DroolsAllBotTests.java
trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/DroolsViewsTest.java
trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageDroolsRuntime.java
trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/RuleFlowTest.java
Log:
Added support for jBPM runtime.
Modified: trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/resources/project.properties
===================================================================
--- trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/resources/project.properties 2012-10-16 09:40:45 UTC (rev 44520)
+++ trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/resources/project.properties 2012-10-16 09:47:12 UTC (rev 44521)
@@ -1,3 +1,5 @@
use-external-drools-runtime=true
-guvnor-repository-url=/jboss-brms/org.drools.guvnor.Guvnor/webdav
external-drools-runtime-home=/home/jgargula/Programs/drools-runtime
+use-external-jbpm-runtime=true
+external-jbpm-runtime-home=/home/jgargula/Programs/jbpm-runtime
+guvnor-repository-url=/jboss-brms/org.drools.guvnor.Guvnor/webdav
\ No newline at end of file
Modified: trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/DroolsAllBotTests.java
===================================================================
--- trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/DroolsAllBotTests.java 2012-10-16 09:40:45 UTC (rev 44520)
+++ trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/DroolsAllBotTests.java 2012-10-16 09:47:12 UTC (rev 44521)
@@ -24,6 +24,7 @@
import org.jboss.tools.drools.ui.bot.test.smoke.ManageDroolsProject;
import org.jboss.tools.drools.ui.bot.test.smoke.ManageDroolsRules;
import org.jboss.tools.drools.ui.bot.test.smoke.ManageDroolsRuntime;
+import org.jboss.tools.drools.ui.bot.test.smoke.ManageJbpmRuntime;
import org.jboss.tools.drools.ui.bot.test.smoke.OpenDroolsPerspective;
import org.jboss.tools.drools.ui.bot.test.smoke.RuleFlowTest;
import org.jboss.tools.ui.bot.ext.RequirementAwareSuite;
@@ -49,6 +50,7 @@
@SuiteClasses({
OpenDroolsPerspective.class,
ManageDroolsRuntime.class,
+ ManageJbpmRuntime.class,
ManageDroolsProject.class,
ManageDroolsRules.class,
DroolsRulesEditorTest.class,
@@ -63,7 +65,10 @@
public static final String DROOLS_PROJECT_NAME = "droolsTest";
public static final String DROOLS_RUNTIME_NAME = "Drools Test Runtime";
public static String DROOLS_RUNTIME_LOCATION = null;
+ public static String JBPM_RUNTIME_LOCATION = null;
+ public static final String JBPM_RUNTIME_NAME = "jBPM Test Runtime";
public static String CREATE_DROOLS_RUNTIME_LOCATION = null;
+ public static String CREATE_JBPM_RUNTIME_LOCATION = null;
public static String SRC_MAIN_JAVA_TREE_NODE = "src/main/java";
public static String SRC_MAIN_RULES_TREE_NODE = "src/main/rules";
public static String COM_SAMPLE_TREE_NODE = "com.sample";
@@ -80,12 +85,17 @@
public static final String DECISION_TABLE_JAVA_TEST_FILE_NAME = "DecisionTableTest.java";
public static final String USE_EXTERNAL_DROOLS_RUNTIME_PROPERTY_NAME = "use-external-drools-runtime";
public static final String EXTERNAL_DROOLS_RUTIME_HOME_PROPERTY_NAME = "external-drools-runtime-home";
+ public static final String USE_EXTERNAL_JBPM_RUNTIME_PROPERTY_NAME = "use-external-jbpm-runtime";
+ public static final String EXTERNAL_JBPM_RUTIME_HOME_PROPERTY_NAME = "external-jbpm-runtime-home";
public static final String GUVNOR_REPOSITORY_URL_PROPERTY_NAME = "guvnor-repository-url";
private static boolean USE_EXTERNAL_DROOLS_RUNTIME;
+ private static boolean USE_EXTERNAL_JBPM_RUNTIME;
private static boolean isFirstRun = true;
private static String testDroolsRuntimeName = null;
private static String testDroolsRuntimeLocation = null;
+ private static String testJbpmRuntimeName = null;
+ private static String testJbpmRuntimeLocation = null;
private static String guvnorRepositoryUrl = null;
private static String guvnorRepositoryRootTreeItem = "http://localhost:8080/jboss-brms/org.drools.guvnor.Guvnor/webdav/";
@@ -105,6 +115,22 @@
DroolsAllBotTests.testDroolsRuntimeLocation = testDroolsRuntimeLocation;
}
+ public static String getTestJbpmRuntimeName() {
+ return testJbpmRuntimeName;
+ }
+
+ public static void setTestJbpmRuntimeName(String testJbmpRuntimeName) {
+ DroolsAllBotTests.testJbpmRuntimeName = testJbmpRuntimeName;
+ }
+
+ public static String getTestJbpmRuntimeLocation() {
+ return testJbpmRuntimeLocation;
+ }
+
+ public static void setTestJbpmRuntimeLocation(String testJbpmRuntimeLocation) {
+ DroolsAllBotTests.testJbpmRuntimeLocation = testJbpmRuntimeLocation;
+ }
+
public static String getGuvnorRepositoryUrl() {
return guvnorRepositoryUrl;
}
@@ -138,7 +164,7 @@
DroolsAllBotTests.USE_EXTERNAL_DROOLS_RUNTIME = useExternalDroolRuntime != null && useExternalDroolRuntime.equalsIgnoreCase("true");
String droolsRuntimeLocation = props.getProperty(DroolsAllBotTests.EXTERNAL_DROOLS_RUTIME_HOME_PROPERTY_NAME);
String tmpDir = System.getProperty("java.io.tmpdir");
- if (droolsRuntimeLocation == null || droolsRuntimeLocation.length() == 0) {
+ if (droolsRuntimeLocation == null || droolsRuntimeLocation.trim().length() == 0) {
DroolsAllBotTests.DROOLS_RUNTIME_LOCATION = tmpDir;
} else {
DroolsAllBotTests.DROOLS_RUNTIME_LOCATION = droolsRuntimeLocation;
@@ -146,6 +172,19 @@
DroolsAllBotTests.CREATE_DROOLS_RUNTIME_LOCATION = tmpDir + File.separator + "drools";
// Create directory for Drools Runtime which will be created as a part of test
new File(DroolsAllBotTests.CREATE_DROOLS_RUNTIME_LOCATION).mkdir();
+
+ String useExternalJbpmRuntime = props.getProperty(DroolsAllBotTests.USE_EXTERNAL_JBPM_RUNTIME_PROPERTY_NAME);
+ DroolsAllBotTests.USE_EXTERNAL_JBPM_RUNTIME = useExternalJbpmRuntime != null && useExternalJbpmRuntime.equalsIgnoreCase("true");
+ String jbpmRuntimeLocation = props.getProperty(DroolsAllBotTests.EXTERNAL_JBPM_RUTIME_HOME_PROPERTY_NAME);
+ if (jbpmRuntimeLocation == null || jbpmRuntimeLocation.trim().length() == 0) {
+ DroolsAllBotTests.JBPM_RUNTIME_LOCATION = tmpDir;
+ } else {
+ DroolsAllBotTests.JBPM_RUNTIME_LOCATION = jbpmRuntimeLocation;
+ }
+ DroolsAllBotTests.CREATE_JBPM_RUNTIME_LOCATION = tmpDir + File.separator + "jBPM";
+ // Create directory for jBPM Runtime which will be created as a part of test
+ new File(DroolsAllBotTests.CREATE_JBPM_RUNTIME_LOCATION).mkdir();
+
try {
bot.button(IDELabel.Button.NO).click();
} catch (WidgetNotFoundException wnfe) {
@@ -204,10 +243,14 @@
public static boolean useExternalDroolsRuntime() {
return USE_EXTERNAL_DROOLS_RUNTIME;
}
+
+ public static boolean useExternalJbpmRuntime() {
+ return USE_EXTERNAL_JBPM_RUNTIME;
+ }
@AfterClass
public static void tearDownTest() {
// delete created drools runtime
SWTUtilExt.deleteDirectory(DroolsAllBotTests.CREATE_DROOLS_RUNTIME_LOCATION);
- }
+ }
}
\ No newline at end of file
Modified: trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/DroolsViewsTest.java
===================================================================
--- trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/DroolsViewsTest.java 2012-10-16 09:40:45 UTC (rev 44520)
+++ trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/DroolsViewsTest.java 2012-10-16 09:47:12 UTC (rev 44521)
@@ -133,7 +133,7 @@
* Test of Agenda view.
*/
@Test
- public void agendaTest() {
+ public void testAgenda() {
bot.editorByTitle(RULES_FILE).show();
eclipse.stepOver();
SWTUtilExt.startCapturingStandardOutput();
@@ -170,7 +170,7 @@
*/
@Test
@Ignore
- public void refreshAgendaTest() {
+ public void testRefreshAgenda() {
openView(IDELabel.View.AGENDA);
eclipse.stepOver();
assertTrue("Agenda is not refreshing automatically.", bot.tree().getAllItems()[0].getItems().length > 0);
@@ -180,7 +180,7 @@
* Test of global variable in Global Data.
*/
@Test
- public void globalDataTest() {
+ public void testGlobalData() {
openView(IDELabel.View.GLOBAL_DATA);
assertTrue("Global data has wrong number of items. Expected 1 but was "
+ bot.tree().getAllItems().length, bot.tree().getAllItems().length == 1);
@@ -193,7 +193,7 @@
* Test of Audit view.
*/
@Test
- public void auditTest() {
+ public void testAudit() {
eclipse.finishDebug();
openView(IDELabel.View.AUDIT);
SWTBotView auditView = bot.viewByTitle(IDELabel.View.AUDIT);
@@ -250,7 +250,7 @@
* Test of Working Memory view
*/
@Test
- public void workingMemoryTest() {
+ public void testWorkingMemory() {
openView(IDELabel.View.WORKING_MEMORY);
SWTBotTree workingMemoryTree = bot.tree();
Modified: trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageDroolsRuntime.java
===================================================================
--- trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageDroolsRuntime.java 2012-10-16 09:40:45 UTC (rev 44520)
+++ trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/ManageDroolsRuntime.java 2012-10-16 09:47:12 UTC (rev 44521)
@@ -25,12 +25,14 @@
import org.jboss.tools.ui.bot.ext.gen.ActionItem;
import org.jboss.tools.ui.bot.ext.types.IDELabel;
import org.junit.Test;
+
/**
* Test managing of Drools Runtime
* @author Vladimir Pakan
*
*/
-public class ManageDroolsRuntime extends SWTTestExt{
+public class ManageDroolsRuntime extends SWTTestExt {
+
/**
* Test manage Drools Runtime
*/
@@ -42,18 +44,19 @@
"edited" , "testedit");
removeDroolsRuntime(DroolsAllBotTests.getTestDroolsRuntimeName());
createDroolsRuntime(DroolsAllBotTests.DROOLS_RUNTIME_NAME,DroolsAllBotTests.CREATE_DROOLS_RUNTIME_LOCATION);
- if (DroolsAllBotTests.useExternalDroolsRuntime()){
+ if (DroolsAllBotTests.useExternalDroolsRuntime()) {
removeDroolsRuntime(DroolsAllBotTests.DROOLS_RUNTIME_NAME);
addDroolsRuntime(DroolsAllBotTests.DROOLS_RUNTIME_NAME,DroolsAllBotTests.DROOLS_RUNTIME_LOCATION,true);
}
}
+
/**
* Adds Drools Runtime
* @param runtimeName
* @param runtimeLocation
* @param setAsDefault
*/
- private void addDroolsRuntime(String runtimeName, String runtimeLocation, boolean setAsDefault){
+ private void addDroolsRuntime(String runtimeName, String runtimeLocation, boolean setAsDefault) {
selectDroolsPreferences();
bot.button(IDELabel.Button.ADD).click();
bot.shell(IDELabel.Shell.DROOLS_RUNTIME).activate();
@@ -66,7 +69,7 @@
SWTEclipseExt.isItemInTableColumn(table,runtimeName,IDELabel.DroolsRuntimeDialog.COLUMN_NAME_INDEX)
&& SWTEclipseExt.isItemInTableColumn(table,runtimeLocation,IDELabel.DroolsRuntimeDialog.COLUMN_LOCATION_INDEX);
// Set new runtime as default
- if (setAsDefault){
+ if (setAsDefault) {
table.getTableItem(0).check();
}
bot.button(IDELabel.Button.OK).click();
@@ -77,13 +80,15 @@
DroolsAllBotTests.setTestDroolsRuntimeLocation(runtimeLocation);
SWTEclipseExt.hideWarningIfDisplayed(bot);
}
+
/**
* Selects Drools Preferences within Preferences Dialog
*/
- private void selectDroolsPreferences(){
+ private void selectDroolsPreferences() {
jbt.delay();
new SWTOpenExt(new SWTBotExt()).preferenceOpen(ActionItem.Preference.DroolsInstalledDroolsRuntimes.LABEL);
}
+
/**
* Edits Drools Runtime
* @param runtimeName
@@ -91,7 +96,7 @@
* @param nameSuffix
* @param locationSuffix
*/
- private void editDroolsRuntime(String runtimeName, String runtimeLocation, String nameSuffix, String locationSuffix){
+ private void editDroolsRuntime(String runtimeName, String runtimeLocation, String nameSuffix, String locationSuffix) {
selectDroolsPreferences();
SWTBotTable table = bot.table();
table.getTableItem(runtimeName).select();
@@ -123,7 +128,7 @@
* @param runtimeName
* @param runtimeLocation
*/
- private void removeDroolsRuntime(String runtimeName){
+ private void removeDroolsRuntime(String runtimeName) {
selectDroolsPreferences();
SWTBotTable table = bot.table();
table.getTableItem(runtimeName).select();
@@ -134,9 +139,9 @@
assertTrue("Drools Runtime with name [" + runtimeName +
"] was not removed properly.",droolsRuntimeRemoved);
// Remove temporary directory created within editDroolsRuntime() method
- if (!DroolsAllBotTests.getTestDroolsRuntimeName().equals(DroolsAllBotTests.DROOLS_RUNTIME_NAME)){
+ if (!DroolsAllBotTests.getTestDroolsRuntimeName().equals(DroolsAllBotTests.DROOLS_RUNTIME_NAME)) {
File tempDir = new File (DroolsAllBotTests.getTestDroolsRuntimeLocation());
- if (tempDir.isDirectory()){
+ if (tempDir.isDirectory()) {
tempDir.delete();
}
}
@@ -144,12 +149,13 @@
DroolsAllBotTests.setTestDroolsRuntimeLocation(null);
SWTEclipseExt.hideWarningIfDisplayed(bot);
}
+
/**
* Creates Drools Runtime
* @param runtimeName
* @param runtimeLocation
*/
- private void createDroolsRuntime(String runtimeName, String runtimeLocation){
+ private void createDroolsRuntime(String runtimeName, String runtimeLocation) {
DroolsRuntimeManager.createDefaultRuntime(runtimeLocation);
DroolsRuntime droolsRuntime = new DroolsRuntime();
droolsRuntime.setName(runtimeName);
@@ -172,7 +178,5 @@
DroolsAllBotTests.setTestDroolsRuntimeName(runtimeName);
DroolsAllBotTests.setTestDroolsRuntimeLocation(runtimeLocation);
- }
-
+ }
}
-
Modified: trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/RuleFlowTest.java
===================================================================
--- trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/RuleFlowTest.java 2012-10-16 09:40:45 UTC (rev 44520)
+++ trunk/build/aggregate/soatests-site/tests/org.jboss.tools.drools.ui.bot.test/src/org/jboss/tools/drools/ui/bot/test/smoke/RuleFlowTest.java 2012-10-16 09:47:12 UTC (rev 44521)
@@ -41,6 +41,7 @@
import org.jboss.tools.ui.bot.ext.SWTUtilExt;
import org.jboss.tools.ui.bot.ext.Timing;
import org.jboss.tools.ui.bot.ext.gen.ActionItem;
+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.junit.Test;
@@ -75,11 +76,22 @@
*/
@Test
public void testRuleFlow() {
+ configureJbpmProject();
runRuleFlowCheck(DroolsAllBotTests.RULE_FLOW_JAVA_TEST_FILE_NAME);
ruleFlowEditorCheck(DroolsAllBotTests.RULE_FLOW_FILE_NAME);
}
/**
+ * Sets jBPM library
+ */
+ private void configureJbpmProject() {
+ SWTBotTree tree = eclipse.showView(ViewType.PACKAGE_EXPLORER).tree();
+ tree.getTreeItem(DroolsAllBotTests.DROOLS_PROJECT_NAME).select();
+ ContextMenuHelper.clickContextMenu(tree, IDELabel.Menu.PACKAGE_EXPLORER_CONFIGURE,
+ IDELabel.Menu.CONVERT_TO_JBPM_PROJECT);
+ }
+
+ /**
* Sets all drools flow nodes.
*/
@SuppressWarnings("unused")
12 years, 4 months