-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add mechanism to recognize Application Server #605
(cherry picked from commit c184140) Conflicts: terasoluna-gfw-functionaltest-env/configs/jboss7-postgresql/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/resin-oracle/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/resin-postgresql/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/tomcat-oracle/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/tomcat-postgresql/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/tomcat8-oracle/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/tomcat8-postgresql/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/tomcat85-oracle/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/tomcat85-postgresql/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/weblogic-oracle/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/webotx-oracle/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/webspherelp-db2/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/configs/webspheretr-db2/resources/META-INF/spring/application-env.properties terasoluna-gfw-functionaltest-env/src/main/resources/META-INF/spring/application-env.properties
- Loading branch information
1 parent
e61715a
commit 2635cef
Showing
12 changed files
with
87 additions
and
7 deletions.
There are no files selected for viewing
3 changes: 2 additions & 1 deletion
3
...ctionaltest-env/configs/resin-oracle/resources/META-INF/spring/application-env.properties
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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
app.redirect.allowed.externalUrl=http://terasolunaorg.github.io | ||
|
||
application.server.name=resin | ||
application.server.version=4 |
3 changes: 2 additions & 1 deletion
3
...naltest-env/configs/resin-postgresql/resources/META-INF/spring/application-env.properties
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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
app.redirect.allowed.externalUrl=http://terasolunaorg.github.io | ||
|
||
application.server.name=resin | ||
application.server.version=4 |
3 changes: 2 additions & 1 deletion
3
...tionaltest-env/configs/tomcat-oracle/resources/META-INF/spring/application-env.properties
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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
app.redirect.allowed.externalUrl=http://terasolunaorg.github.io | ||
|
||
application.server.name=tomcat | ||
application.server.version=7 |
3 changes: 2 additions & 1 deletion
3
...altest-env/configs/tomcat-postgresql/resources/META-INF/spring/application-env.properties
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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
app.redirect.allowed.externalUrl=http://terasolunaorg.github.io | ||
|
||
application.server.name=tomcat | ||
application.server.version=7 |
3 changes: 2 additions & 1 deletion
3
...ltest-env/configs/tomcat8-postgresql/resources/META-INF/spring/application-env.properties
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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
app.redirect.allowed.externalUrl=http://terasolunaorg.github.io | ||
|
||
application.server.name=tomcat | ||
application.server.version=8.0 |
3 changes: 2 additions & 1 deletion
3
...onaltest-env/configs/weblogic-oracle/resources/META-INF/spring/application-env.properties
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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
app.redirect.allowed.externalUrl=http://terasolunaorg.github.io | ||
|
||
application.server.name=weblogic | ||
application.server.version=12 |
6 changes: 5 additions & 1 deletion
6
...luna-gfw-functionaltest-env/src/main/resources/META-INF/spring/application-env.properties
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 |
---|---|---|
@@ -1,2 +1,6 @@ | ||
app.redirect.allowed.externalUrl=http://terasolunaorg.github.io | ||
|
||
## application server name and version properties are used in order to | ||
## change the assertions in test which depends on application server. | ||
## when the new profile is added, set appropriate values. | ||
application.server.name=tomcat | ||
application.server.version=8.0 |
12 changes: 12 additions & 0 deletions
12
...tionaltest-selenium/src/test/java/org/terasoluna/gfw/functionaltest/app/ApServerName.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,12 @@ | ||
package org.terasoluna.gfw.functionaltest.app; | ||
|
||
/** | ||
* Enumeration class for identifying application server. | ||
* <p> | ||
* If application server name is not set in application.env.properties, <br/> | ||
* UNKNOWN is set. | ||
* </p> | ||
*/ | ||
public enum ApServerName { | ||
UNKNOWN, RESIN, TOMCAT, WEBLOGIC | ||
} |
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
15 changes: 15 additions & 0 deletions
15
...test-web/src/main/java/org/terasoluna/gfw/functionaltest/config/PropertySourceConfig.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,15 @@ | ||
package org.terasoluna.gfw.functionaltest.config; | ||
|
||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.context.annotation.PropertySource; | ||
|
||
/** | ||
* Class that registers the value defined in application-env.properties of each profile in environment. | ||
* <p> | ||
* Passes application server information to WebDriver through JSP so that asserts can be changed for each application server. | ||
* </p> | ||
*/ | ||
@Configuration | ||
@PropertySource("classpath:/META-INF/spring/application-env.properties") | ||
public class PropertySourceConfig { | ||
} |
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