Skip to content

Commit

Permalink
[WISE-260] added GUI testsuite module and moved src dir into gui dir.…
Browse files Browse the repository at this point in the history
… Removed unneeded dependency in testsuite.
  • Loading branch information
rsearls committed Jan 8, 2016
1 parent 9a2a87a commit 4fe094c
Show file tree
Hide file tree
Showing 132 changed files with 2,509 additions and 240 deletions.
24 changes: 18 additions & 6 deletions README.md
Expand Up @@ -4,13 +4,25 @@ console was implemented using MVP design pattern.

Project Directories

src/main/java/org/jboss/wise/gwt ; GWT display components
src/main/java/org/jboss/wise/gwt/shared ; Data structs shared between the UI and backend
src/main/java/org/jboss/wise/gwt/client ; MVC, GWT module components and directory
gui/src/main/java/org/jboss/wise/gwt ; GWT display components
gui/src/main/java/org/jboss/wise/gwt/shared ; Data structs shared between the UI and backend
gui/src/main/java/org/jboss/wise/gwt/client ; MVC, GWT module components and directory
; structure as required by GWT
src/main/java/org/jboss/wise/gui ; Preexisting classes that interface with wise-core
src/main/java/org/jboss/wise/gui/treeElement
src/main/java/org/jboss/wise/shared ; classes shared by gwt and gui classes
gui/src/main/java/org/jboss/wise/gui ; Preexisting classes that interface with wise-core
gui/src/main/java/org/jboss/wise/gui/treeElement
gui/src/main/java/org/jboss/wise/shared ; classes shared by gwt and gui classes


Arquillian based Selenium tests are provided in the testsuite directory.
They can be run under 4 profiles, wildfly800, wildfly810, wildfly820, wildfly900.

Prerequisites
1. JDK 1.8
2. Firefox 38 or higher
3. gui/target/wise-gwt-gui-<version>.war

1. Build the gui/target/wise-gwt-gui-<version>.war
From the project root directory run 'mvn clean install'
2. cd into testsuite
mvn test -Pwildfly<version>

234 changes: 234 additions & 0 deletions gui/pom.xml
@@ -0,0 +1,234 @@
<?xml version="1.0" encoding="UTF-8"?>
<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>


<parent>
<groupId>org.jboss.wise</groupId>
<artifactId>wise-gwt</artifactId>
<version>1.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

<name>Wise GWT GUI</name>
<artifactId>wise-gwt-gui</artifactId>
<packaging>war</packaging>
<description>A GWT-based GUI for JBoss Wise Core</description>


<properties>
<webappDirectory>${project.build.directory}/${project.build.finalName}</webappDirectory>
</properties>

<dependencies>

<dependency>
<groupId>javax.enterprise</groupId>
<artifactId>cdi-api</artifactId>
</dependency>

<dependency>
<groupId>org.jboss.spec.javax.ejb</groupId>
<artifactId>jboss-ejb-api_3.1_spec</artifactId>
</dependency>

<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-servlet</artifactId>
<scope>runtime</scope>
</dependency>

<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.jboss.wise</groupId>
<artifactId>wise-core-cxf</artifactId>
<exclusions>
<exclusion>
<groupId>org.jboss.ws</groupId>
<artifactId>jbossws-common</artifactId>
</exclusion>
<exclusion>
<groupId>org.jboss.ws</groupId>
<artifactId>jbossws-spi</artifactId>
</exclusion>
<exclusion>
<groupId>org.jboss.ws.cxf</groupId>
<artifactId>jbossws-cxf-client</artifactId>
</exclusion>
<exclusion>
<groupId>xalan</groupId>
<artifactId>xalan</artifactId>
</exclusion>
<exclusion>
<groupId>wsdl4j</groupId>
<artifactId>wsdl4j</artifactId>
</exclusion>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>
<exclusion>
<groupId>org.freemarker</groupId>
<artifactId>freemarker</artifactId>
</exclusion>
<exclusion>
<groupId>javassist</groupId>
<artifactId>javassist</artifactId>
</exclusion>
<exclusion>
<groupId>org.milyn</groupId>
<artifactId>milyn-smooks-javabean</artifactId>
</exclusion>
<exclusion>
<groupId>org.milyn</groupId>
<artifactId>milyn-smooks-validation</artifactId>
</exclusion>
<exclusion>
<groupId>com.thoughtworks.xstream</groupId>
<artifactId>xstream</artifactId>
</exclusion>
<exclusion>
<groupId>org.mvel</groupId>
<artifactId>mvel2</artifactId>
</exclusion>
<exclusion>
<groupId>dtdparser</groupId>
<artifactId>dtdparser</artifactId>
</exclusion>
</exclusions>
</dependency>

<dependency>
<groupId>org.wildfly.core</groupId>
<artifactId>wildfly-controller-client</artifactId>
</dependency>

</dependencies>
<build>
<!-- Generate compiled stuff in the folder used for developing mode -->
<outputDirectory>${webappDirectory}/WEB-INF/classes</outputDirectory>

<plugins>

<!-- GWT Maven Plugin -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>gwt-maven-plugin</artifactId>
<version>${gwtVersion}</version>
<executions>
<execution>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
<!-- Plugin configuration. There are many available options, see
gwt-maven-plugin documentation at codehaus.org -->
<configuration>
<module>org.jboss.wise.Wise</module>
<runTarget>Main.html</runTarget>
<hostedWebapp>${webappDirectory}</hostedWebapp>
</configuration>
</plugin>

<!-- Copy static web files before executing gwt:run -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.1.1</version>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>exploded</goal>
</goals>
</execution>
</executions>
<configuration>
<webappDirectory>${webappDirectory}</webappDirectory>
</configuration>
</plugin>


<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>${version.compiler.plugin}</version>

<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>

</plugins>
</build>

<profiles>
<!-- [JBWS-3666] -->
<profile>
<id>eclipse-m2e</id>
<activation>
<property>
<name>!eclipse-m2e</name>
</property>
</activation>
<build>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself. -->
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<versionRange>[2.1.1,)</versionRange>
<goals>
<goal>exploded</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
</profile>
</profiles>

</project>
File renamed without changes.
Expand Up @@ -125,7 +125,7 @@ public void performInvocation() throws WiseWebServiceException, WiseProcessingEx
}
}

public void generateRequestPreview() throws WiseProcessingException {
public void generateRequestPreview() {

requestPreview = null;
try {
Expand All @@ -137,7 +137,6 @@ public void generateRequestPreview() throws WiseProcessingException {
} catch (Exception e) {
requestPreview = ClientHelper.toErrorMessage(e);
logException(e);
throw new WiseProcessingException(requestPreview, e.getCause());
}
}

Expand Down
Expand Up @@ -46,7 +46,7 @@ public interface MainService extends RemoteService {
WsdlAddress getAddress(String id);
List<Service> getEndpoints(WsdlInfo wsdlInfo) throws WiseProcessingException;
RequestResponse getEndpointReflection(String id);
String getRequestPreview(TreeElement rootTreeElement) throws WiseProcessingException ;
String getRequestPreview(TreeElement rootTreeElement);
RequestResponse getPerformInvocationOutputTree(TreeElement rootTreeElement,
WsdlInfo wsdlInfo) throws WiseWebServiceException, WiseProcessingException;
boolean isValidURL(String url) throws WiseURLException;
Expand Down
Expand Up @@ -278,7 +278,7 @@ public void onSuccess(String result) {

public void onFailure(Throwable caught) {

Window.alert("ERROR: " + caught.getMessage());
Window.alert("Error processing getRequestPreview");
}
});
}
Expand Down
Expand Up @@ -162,6 +162,7 @@ protected WiseTreeItem generateDisplayObject(WiseTreeItem parentItem,

if (TreeElement.SIMPLE.equals(parentTreeElement.getKind())) {
WiseTreeItem treeItem = new WiseTreeItem();
treeItem.addStyleName("wise-input-row");
HorizontalPanel hPanel = new HorizontalPanel();
treeItem.setWidget(hPanel);
treeItem.setState(true);
Expand All @@ -170,6 +171,7 @@ protected WiseTreeItem generateDisplayObject(WiseTreeItem parentItem,
+ parentTreeElement.getName());
Widget widget = getWidget(parentTreeElement);
widget.addStyleName(WiseTreeItem.CSS_ENABLEBLK);
widget.addStyleName("wise-gwt-inputBox");
hPanel.add(label);

SimpleCheckBox checkBox = null;
Expand Down Expand Up @@ -246,6 +248,7 @@ protected WiseTreeItem generateDisplayObject(WiseTreeItem parentItem,

HorizontalPanel gPanel = new HorizontalPanel();
Button addButton = new Button("add");
addButton.addStyleName("wise-gwt-button-add");
gPanel.add(new Label(getBaseType(parentTreeElement.getClassType())
+ "<" + getBaseType(gChild.getClassType()) + ">"
+ " : " + parentTreeElement.getName()));
Expand Down Expand Up @@ -404,6 +407,7 @@ public void onClick(ClickEvent event) {
endpointConfigView.generateDisplayObject(treeItem, cloneChild);

Button rmButton = new Button("remove");
rmButton.addStyleName("wise-gwt-button-remove");
int cnt = treeItem.getChildCount();
WiseTreeItem childTreeItem = (WiseTreeItem) treeItem.getChild(cnt - 1);

Expand Down
Expand Up @@ -147,6 +147,7 @@ protected TreeItem generateDisplayObject(TreeItem parentItem, TreeElement parent

Label label = new Label(getClassType(parentTreeElement) + parentTreeElement.getName() + " = "
+ ((SimpleTreeElement)parentTreeElement).getValue());
label.addStyleName("wise-result-treeItem");
hPanel.add(label);
parentItem.addItem(treeItem);

Expand Down
Expand Up @@ -86,6 +86,7 @@ private HorizontalPanel createInputDetails() {
contentDetailsPanel.add(new Label("URL: "));
wsdlAddress = new TextBox();
wsdlAddress.setVisibleLength(56);
wsdlAddress.addStyleName("wsdl.input.box");
contentDetailsPanel.add(wsdlAddress);
errorLabel = new Label("Invalid URL");
contentDetailsPanel.add(errorLabel);
Expand Down
Expand Up @@ -22,6 +22,9 @@ public MenuPanel() {
backButton.addStyleName("wise-gwt-Button");
nextButton.addStyleName("wise-gwt-Button");

backButton.addStyleName("wise-gwt-Button-back");
nextButton.addStyleName("wise-gwt-Button-next");

add(backButton);
add(nextButton);
}
Expand Down

0 comments on commit 4fe094c

Please sign in to comment.