This repository has been archived by the owner on Jun 7, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rearrange and test servlet-based examples.
- Loading branch information
1 parent
01c939e
commit ea7e554
Showing
11 changed files
with
151 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
servlet/servlet-cdi/src/it/java/org/wildfly/swarm/it/servlet/cdi/ServletApplicationIT.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package org.wildfly.swarm.it.servlet.cdi; | ||
|
||
import org.jboss.arquillian.drone.api.annotation.Drone; | ||
import org.jboss.arquillian.junit.Arquillian; | ||
import org.junit.Test; | ||
import org.junit.runner.RunWith; | ||
import org.openqa.selenium.WebDriver; | ||
import org.wildfly.swarm.it.AbstractIntegrationTest; | ||
|
||
import static org.fest.assertions.Assertions.assertThat; | ||
|
||
/** | ||
* @author Bob McWhirter | ||
*/ | ||
@RunWith(Arquillian.class) | ||
public class ServletApplicationIT extends AbstractIntegrationTest { | ||
|
||
@Drone | ||
WebDriver browser; | ||
|
||
@Test | ||
public void testIt() { | ||
browser.navigate().to("http://localhost:8080/"); | ||
assertThat(browser.getPageSource()).contains("Howdy at "); | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
...g/wildfly/swarm/examples/cdi/Greeter.java → ...y/swarm/examples/servlet/cdi/Greeter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...wildfly/swarm/examples/cdi/MyServlet.java → ...swarm/examples/servlet/cdi/MyServlet.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
~ Copyright 2015 Red Hat, Inc. and/or its affiliates. | ||
~ | ||
~ Licensed under the Apache License version 2.0, available at http://www.apache.org/licenses/LICENSE-2.0 | ||
--> | ||
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<parent> | ||
<groupId>org.wildfly.swarm.examples</groupId> | ||
<artifactId>examples-servlet</artifactId> | ||
<version>1.0.0.Alpha6-SNAPSHOT</version> | ||
<relativePath>../</relativePath> | ||
</parent> | ||
|
||
<artifactId>example-servlet-war</artifactId> | ||
|
||
<name>WildFly Swarm Examples: Servlet .war</name> | ||
<description>WildFly Swarm Examples: Servlet .war</description> | ||
|
||
<packaging>war</packaging> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-war-plugin</artifactId> | ||
<configuration> | ||
<failOnMissingWebXml>false</failOnMissingWebXml> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.wildfly.swarm</groupId> | ||
<artifactId>wildfly-swarm-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<id>package</id> | ||
</execution> | ||
<execution> | ||
<id>start</id> | ||
</execution> | ||
<execution> | ||
<id>stop</id> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.wildfly.swarm.examples</groupId> | ||
<artifactId>examples-base</artifactId> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.wildfly.swarm</groupId> | ||
<artifactId>wildfly-swarm-undertow</artifactId> | ||
<version>${version.wildfly-swarm}</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>joda-time</groupId> | ||
<artifactId>joda-time</artifactId> | ||
<version>2.7</version> | ||
</dependency> | ||
</dependencies> | ||
|
||
</project> |
26 changes: 26 additions & 0 deletions
26
servlet/servlet-war/src/it/java/org/wildfly/swarm/it/servlet/ServletApplicationIT.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package org.wildfly.swarm.it.servlet; | ||
|
||
import org.jboss.arquillian.drone.api.annotation.Drone; | ||
import org.jboss.arquillian.junit.Arquillian; | ||
import org.junit.Test; | ||
import org.junit.runner.RunWith; | ||
import org.openqa.selenium.WebDriver; | ||
import org.wildfly.swarm.it.AbstractIntegrationTest; | ||
|
||
import static org.fest.assertions.Assertions.assertThat; | ||
|
||
/** | ||
* @author Bob McWhirter | ||
*/ | ||
@RunWith(Arquillian.class) | ||
public class ServletApplicationIT extends AbstractIntegrationTest { | ||
|
||
@Drone | ||
WebDriver browser; | ||
|
||
@Test | ||
public void testIt() { | ||
browser.navigate().to("http://localhost:8080/"); | ||
assertThat(browser.getPageSource()).contains("Howdy at "); | ||
} | ||
} |
File renamed without changes.