Class TestConfig
- java.lang.Object
-
- org.kie.server.integrationtests.config.TestConfig
-
public class TestConfig extends Object
Class contains all test configurations and its basic handling.
-
-
Constructor Summary
Constructors Constructor Description TestConfig()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static StringgetCargoRemotePassword()static StringgetCargoRemoteUsername()static StringgetConnectionFactory()Get connection factory JNDI name defined in container to create JMS messages.static StringgetContainerId()static StringgetContainerPort()static IntegergetControllerAllocatedPort()Get allocated port of embedded REST server.static StringgetControllerHttpUrl()Get kie-servers controller URL for HTTP services - like REST.static StringgetControllerWebSocketManagementUrl()Get kie-servers controller management URL for WebSocket service.static StringgetEmbeddedKieServerHttpUrl()Get embedded kie-server URL for HTTP services - like REST.static StringgetInitialContextFactory()Get initial context factory class name for creating context factory used in JMS.static InitialContextgetInitialRemoteContext()static StringgetJbossManagementPort()static StringgetKieClientDeploymentSettings()static IntegergetKieServerAllocatedPort()Get allocated port of embedded REST server.static StringgetKieServerContext()static StringgetKieServerControllerContext()static StringgetKieServerDataSourceDriverClass()static StringgetKieServerHttpUrl()Get kie-server URL for HTTP services - like REST.static StringgetKieServerLocalRepoDir()static StringgetKieServerMavenSettings()static StringgetKieServerRemoteRepoDir()static StringgetKieServerWarPath()static StringgetKjarsBuildSettingsXml()static StringgetPassword()Get password of user registered in container.static StringgetRemotingUrl()Get URL which is used for remoting services like JMS.static StringgetRequestQueueJndi()Get JNDI name of request queue for kie server.static StringgetResponseQueueJndi()Get JNDI name of response queue for kie server.static IntegergetRouterAllocatedPort()Get allocated port of embedded REST server.static StringgetUsername()Get username of user registered in container.static StringgetWebLogicHome()static StringgetWebServiceHttpURL()static booleanisCargoRemotePasswordProvided()static booleanisCargoRemoteUsernameProvided()static booleanisControllerProvided()Check if controller should be present.static booleanisJbossManagementPortProvided()static booleanisLocalServer()Used for detecting if we run test with local embedded server.static booleanisMariaDbDataSource()static booleanisMySqlDataSource()static booleanisSybaseDataSource()static booleanisWebLogicHomeProvided()static booleanskipJMS()Allows to skip JMS tests by placing on the classpath empty file 'jms.skip'static booleanstartRouter()Allows to start router by placing on the classpath empty file 'router.start'
-
-
-
Method Detail
-
getWebServiceHttpURL
public static String getWebServiceHttpURL()
- Returns:
- webservice http url.
-
getKieServerHttpUrl
public static String getKieServerHttpUrl()
Get kie-server URL for HTTP services - like REST.- Returns:
- HTTP URL.
-
getEmbeddedKieServerHttpUrl
public static String getEmbeddedKieServerHttpUrl()
Get embedded kie-server URL for HTTP services - like REST.- Returns:
- HTTP URL.
-
getControllerHttpUrl
public static String getControllerHttpUrl()
Get kie-servers controller URL for HTTP services - like REST.- Returns:
- controller HTTP URL.
-
getControllerWebSocketManagementUrl
public static String getControllerWebSocketManagementUrl()
Get kie-servers controller management URL for WebSocket service.- Returns:
- controller management WS URL.
-
isControllerProvided
public static boolean isControllerProvided()
Check if controller should be present.- Returns:
- controller HTTP URL.
-
getKieServerAllocatedPort
public static Integer getKieServerAllocatedPort()
Get allocated port of embedded REST server.- Returns:
- HTTP port number.
-
getControllerAllocatedPort
public static Integer getControllerAllocatedPort()
Get allocated port of embedded REST server.- Returns:
- HTTP port number.
-
getRouterAllocatedPort
public static Integer getRouterAllocatedPort()
Get allocated port of embedded REST server.- Returns:
- HTTP port number.
-
skipJMS
public static boolean skipJMS()
Allows to skip JMS tests by placing on the classpath empty file 'jms.skip'- Returns:
-
startRouter
public static boolean startRouter()
Allows to start router by placing on the classpath empty file 'router.start'- Returns:
-
isLocalServer
public static boolean isLocalServer()
Used for detecting if we run test with local embedded server.- Returns:
- True if local embedded server is used.
-
getUsername
public static String getUsername()
Get username of user registered in container.- Returns:
- username.
-
getPassword
public static String getPassword()
Get password of user registered in container.- Returns:
- password.
-
getInitialContextFactory
public static String getInitialContextFactory()
Get initial context factory class name for creating context factory used in JMS.- Returns:
- Initial context factory class name.
-
getConnectionFactory
public static String getConnectionFactory()
Get connection factory JNDI name defined in container to create JMS messages.- Returns:
- Connection factory JNDI name.
-
getRemotingUrl
public static String getRemotingUrl()
Get URL which is used for remoting services like JMS.- Returns:
- URL for remoting service.
-
getRequestQueueJndi
public static String getRequestQueueJndi()
Get JNDI name of request queue for kie server.- Returns:
- Request queue JNDI name.
-
getResponseQueueJndi
public static String getResponseQueueJndi()
Get JNDI name of response queue for kie server.- Returns:
- Response queue JNDI name.
-
getInitialRemoteContext
public static InitialContext getInitialRemoteContext()
- Returns:
- Initial context for connecting to remote server.
-
getKjarsBuildSettingsXml
public static String getKjarsBuildSettingsXml()
- Returns:
- location of the settings.xml file that should be used when building testing kjars
-
getContainerId
public static String getContainerId()
- Returns:
- Cargo container ID.
-
getKieServerContext
public static String getKieServerContext()
- Returns:
- Kie server context value.
-
getKieServerControllerContext
public static String getKieServerControllerContext()
- Returns:
- Kie server controller context value.
-
getKieServerWarPath
public static String getKieServerWarPath()
- Returns:
- Path to Kie server WAR file.
-
getContainerPort
public static String getContainerPort()
- Returns:
- Servlet port to container.
-
getJbossManagementPort
public static String getJbossManagementPort()
- Returns:
- JBoss management port.
-
isJbossManagementPortProvided
public static boolean isJbossManagementPortProvided()
- Returns:
- True if JBoss management port is provided.
-
getWebLogicHome
public static String getWebLogicHome()
- Returns:
- Servlet port to container.
-
isWebLogicHomeProvided
public static boolean isWebLogicHomeProvided()
- Returns:
- Servlet port to container.
-
getCargoRemoteUsername
public static String getCargoRemoteUsername()
- Returns:
- Username for Cargo remote deployment.
-
isCargoRemoteUsernameProvided
public static boolean isCargoRemoteUsernameProvided()
- Returns:
- True if username for Cargo remote deployment defined.
-
getCargoRemotePassword
public static String getCargoRemotePassword()
- Returns:
- Password for Cargo remote deployment.
-
isCargoRemotePasswordProvided
public static boolean isCargoRemotePasswordProvided()
- Returns:
- True if password for Cargo remote deployment defined.
-
getKieClientDeploymentSettings
public static String getKieClientDeploymentSettings()
- Returns:
- location of custom kie-server-testing-client-deployment-settings.xml
-
getKieServerDataSourceDriverClass
public static String getKieServerDataSourceDriverClass()
- Returns:
- FQCN of datasource driver class which is used for currently used database
-
getKieServerMavenSettings
public static String getKieServerMavenSettings()
- Returns:
- Location of settings.xml file used for Kie server maven settings.
-
getKieServerRemoteRepoDir
public static String getKieServerRemoteRepoDir()
- Returns:
- Location of Kie server remote repo directory.
-
getKieServerLocalRepoDir
public static String getKieServerLocalRepoDir()
- Returns:
- Location of Kie server local repo directory.
-
isSybaseDataSource
public static boolean isSybaseDataSource()
- Returns:
- True if Sybase DB is currently used
-
isMySqlDataSource
public static boolean isMySqlDataSource()
- Returns:
- True if MySQL DB is currently used
-
isMariaDbDataSource
public static boolean isMariaDbDataSource()
- Returns:
- True if Maria DB is currently used
-
-