| org.objectweb.jonas.jonasadmin.test.util.JonasAdminTestCase
All known Subclasses: org.objectweb.jonas.jonasadmin.test.service.security.F_JonasAdminServiceSecurity, org.objectweb.jonas.jonasadmin.test.service.mail.C_JonasAdminServiceMail, org.objectweb.jonas.jonasadmin.test.domain.C_JonasAdminDomain, org.objectweb.jonas.jonasadmin.test.service.resource.C_JonasAdminServiceResource, org.objectweb.jonas.jonasadmin.test.service.container.F_JonasAdminWebContainer, org.objectweb.jonas.jonasadmin.test.deploy.F_JonasAdminDeployRar, org.objectweb.jonas.jonasadmin.test.deploy.F_JonasAdminDeployJar, org.objectweb.jonas.jonasadmin.test.monitoring.F_JonasAdminActivatedMonitoring, org.objectweb.jonas.jonasadmin.test.joram.F_JonasAdminJoramProperties, org.objectweb.jonas.jonasadmin.test.jonasserver.C_JonasAdminJonasserver, org.objectweb.jonas.jonasadmin.test.service.security.C_JonasAdminServiceSecurity, org.objectweb.jonas.jonasadmin.test.joram.F_JonasAdminJoramDestination, org.objectweb.jonas.jonasadmin.test.deploy.F_JonasAdminDeploy, org.objectweb.jonas.jonasadmin.test.service.container.C_JonasAdminContainer, org.objectweb.jonas.jonasadmin.test.deploy.F_JonasAdminDeployWar, org.objectweb.jonas.jonasadmin.test.monitoring.F_JonasAdminRange, org.objectweb.jonas.jonasadmin.test.service.discovery.F_JonasAdminDiscovery, org.objectweb.jonas.jonasadmin.test.service.container.F_JonasAdminEjbContainer, org.objectweb.jonas.jonasadmin.test.service.resource.F_JonasAdminResource, org.objectweb.jonas.jonasadmin.test.resource.C_JonasAdminResource, org.objectweb.jonas.jonasadmin.test.service.discovery.C_JonasAdminServiceDiscovery, org.objectweb.jonas.jonasadmin.test.service.mail.F_JonasAdminServiceMail, org.objectweb.jonas.jonasadmin.test.resource.F_JonasAdminResourceDatasource, org.objectweb.jonas.jonasadmin.test.navigation.C_JonasAdminNavigation, org.objectweb.jonas.jonasadmin.test.logging.C_JonasAdminLogging, org.objectweb.jonas.jonasadmin.test.jonasserver.F_JonasAdminInfoServer, org.objectweb.jonas.jonasadmin.test.catalina.C_JonasAdminCatalina, org.objectweb.jonas.jonasadmin.test.monitoring.F_JonasAdminNumberOfMeasures, org.objectweb.jonas.jonasadmin.test.domain.F_JonasAdminDomain, org.objectweb.jonas.jonasadmin.test.service.database.F_JonasAdminDatabase, org.objectweb.jonas.jonasadmin.test.suite.C_JonasAdmin, org.objectweb.jonas.jonasadmin.test.joram.F_JonasAdminJoramUser, org.objectweb.jonas.jonasadmin.test.service.database.C_JonasAdminServiceDatabase, org.objectweb.jonas.jonasadmin.test.monitoring.C_JonasAdminMonitoring, org.objectweb.jonas.jonasadmin.test.logging.F_JonasAdminLogger, org.objectweb.jonas.jonasadmin.test.deploy.C_JonasAdminDeploy, org.objectweb.jonas.jonasadmin.test.service.jtm.C_JonasAdminServiceTransaction, org.objectweb.jonas.jonasadmin.test.service.container.F_JonasAdminApplicationContainer, org.objectweb.jonas.jonasadmin.test.resource.F_JonasAdminResourceMail, org.objectweb.jonas.jonasadmin.test.navigation.F_JonasAdminNavigation, org.objectweb.jonas.jonasadmin.test.joram.C_JonasAdminJoram, org.objectweb.jonas.jonasadmin.test.service.jtm.F_JonasAdminServiceTransaction, org.objectweb.jonas.jonasadmin.test.jonasserver.F_JonasAdminSaveAll, org.objectweb.jonas.jonasadmin.test.template.F_JonasAdminTemplate, org.objectweb.jonas.jonasadmin.test.navigation.F_JonasAdminLogout, org.objectweb.jonas.jonasadmin.test.catalina.F_JonasAdminConnector, org.objectweb.jonas.jonasadmin.test.template.C_JonasAdminTemplate, org.objectweb.jonas.jonasadmin.test.domain.F_JonasAdminDomainAddServer,
JonasAdminTestCase | public class JonasAdminTestCase extends TestCase (Code) | | Define a class to add useful methods for test the examples
- Deploy ear, war and beans
- Retrieve initial context
author: Florent Benoit |
Method Summary | |
protected void | callMainMethod(String classToLoad) | protected void | callMainMethod(String classToLoad, String[] args) | protected void | closeMBeanServer() | protected void | createLocalJmsUser(String name, String password) | protected void | createMailFactory(String mailFactory, Properties properties) | protected void | createQueue(String name, int idString) | protected void | createTopic(String name, int idString) | public void | debug(String msg) | protected String | getAbsoluteUrl(String url) | protected Integer | getIntegerMBeanAttribute(ObjectName on, String attName) | protected ObjectName | getJCAConnectionFactory(String name, String jcaResourceName) | protected MBeanServerConnection | getMBeanServer() | protected String | getStringMBeanAttribute(ObjectName on, String attName) | protected String | getTime() | protected boolean | isDatabaseService() | protected boolean | isInMailFactoryList(String mailFactory) | protected boolean | isJoramRar() | protected boolean | isLoadedDatasource(String datasource) | public boolean | isRarLoaded(String filename) | protected void | setUp() Common setUp routine, used for every test. | public void | tearDown() | protected void | testTabs(WebTable tabTable, int nbTabs, int selectedTab, String msg) | protected void | unBindMailFactory(String mailFactory) | public void | unUseBeans(String filename) | protected void | unUseDatasource(String datasource) | public void | unUseEar(String filename) | protected void | undeployAll(WebResponse wr) | protected void | undeployAllEar() | protected void | undeployAllJar() | protected void | undeployEar(String name) | public void | useBeans(String filename) | protected void | useDatasource(String datasource, Properties properties) | public void | useEar(String filename) | public void | useRar(String filename) | public void | useWar(String filename) |
FRAME_CONTENT | final protected static String FRAME_CONTENT(Code) | | NAME of FRAME content
|
FRAME_TOP | final protected static String FRAME_TOP(Code) | | NAME of FRAME top
|
FRAME_TREE | final protected static String FRAME_TREE(Code) | | NAME of FRAME tree
|
URL_JONASADMIN | final protected static String URL_JONASADMIN(Code) | | URL of the login page
|
URL_JONASADMIN_DEPLOYEAR | final protected static String URL_JONASADMIN_DEPLOYEAR(Code) | | URL of the deployment of EARs
|
URL_JONASADMIN_DEPLOYJAR | final protected static String URL_JONASADMIN_DEPLOYJAR(Code) | | URL of the deployment of JARs
|
prefixUrl | protected String prefixUrl(Code) | | Prefix for build URLs
|
urlLogOut | protected String urlLogOut(Code) | | URL used to log out
|
urlWelcome | protected String urlWelcome(Code) | | URL used to return to Welcome.jsp
|
wc | protected static WebConversation wc(Code) | | Conversation used for HttpUnit
|
JonasAdminTestCase | public JonasAdminTestCase(String s)(Code) | | Constructor with a specified name
Parameters: s - the name |
JonasAdminTestCase | public JonasAdminTestCase(String s, String url)(Code) | | Constructor with a specified name and url
Parameters: s - the name Parameters: url - the url which can be used |
callMainMethod | protected void callMainMethod(String classToLoad) throws Exception(Code) | | Call the main method of a specific class with empty args
Parameters: classToLoad - name of class which contains the main method throws: Exception - if it fails |
callMainMethod | protected void callMainMethod(String classToLoad, String[] args) throws Exception(Code) | | Call the main method of a specific class and the specific args
Parameters: classToLoad - name of class which contains the main method Parameters: args - args to give to the main method throws: Exception - if it fails |
closeMBeanServer | protected void closeMBeanServer() throws Exception(Code) | | Close MBean Server connection
throws: Exception - if an error occurs |
createLocalJmsUser | protected void createLocalJmsUser(String name, String password) throws Exception(Code) | | Create a user in a joram server
Parameters: name - name of the user Parameters: password - password of the user throws: Exception - if an error occurs |
createMailFactory | protected void createMailFactory(String mailFactory, Properties properties) throws Exception(Code) | | Create a mail factory in jonas server
Parameters: mail - factory name of the datasource Parameters: properties - properties of the mail factory throws: Exception - if an error occurs |
createQueue | protected void createQueue(String name, int idString) throws Exception(Code) | | Create a queue in a joram server
Parameters: name - name of the queue Parameters: idString - id of the current joram server throws: Exception - if an error occurs |
createTopic | protected void createTopic(String name, int idString) throws Exception(Code) | | Create a topic in a joram server
Parameters: name - name of the topic Parameters: idString - id of the current joram server throws: Exception - if an error occurs |
debug | public void debug(String msg)(Code) | | Print a debug message
Parameters: msg - The message |
getAbsoluteUrl | protected String getAbsoluteUrl(String url)(Code) | | Add to the specified url the prefix
Parameters: url - relative URL absolute path of URL |
getTime | protected String getTime()(Code) | | Get current time
A String Time with the format yyyy-MM-dd.HH-mm-ss |
isDatabaseService | protected boolean isDatabaseService() throws Exception(Code) | | Check if database service is started (dbm)
true if dbm started throws: Exception - if an error occurs |
isInMailFactoryList | protected boolean isInMailFactoryList(String mailFactory) throws Exception(Code) | | Return if the mail factory is in mail factory list
Parameters: mailFactory - the name of the mail factory true if the mail factory is in list, false else. throws: Exception - if an error occurs. |
isJoramRar | protected boolean isJoramRar() throws Exception(Code) | | Check if the Joram RAR is deplyed
true if dbm started throws: Exception - if an error occurs |
isLoadedDatasource | protected boolean isLoadedDatasource(String datasource) throws Exception(Code) | | Load a datasource in jonas server
Parameters: datasource - name of the datasource boolean true if the datasource is loaded, false else throws: Exception - if an error occurs |
isRarLoaded | public boolean isRarLoaded(String filename) throws Exception(Code) | | Rar is loaded in the jonas server
Parameters: filename - rar file, without ".rar" extension true if the rar is loaded, else false throws: Exception - if an error occurs |
setUp | protected void setUp() throws Exception(Code) | | Common setUp routine, used for every test.
throws: Exception - if an error occurs |
testTabs | protected void testTabs(WebTable tabTable, int nbTabs, int selectedTab, String msg)(Code) | | Verify number of tabs and the selected tab
Parameters: tabTable - the tab table Parameters: nbTabs - number of tabs Parameters: selectedTab - the numero of the selected tab |
unBindMailFactory | protected void unBindMailFactory(String mailFactory) throws Exception(Code) | | Unbind a mail factory in jonas server
Parameters: mailFactory - name of the mail factory throws: Exception - if an error occurs |
unUseBeans | public void unUseBeans(String filename) throws Exception(Code) | | Unload a bean jar file in the jonas server
Parameters: filename - jar file, without ".jar" extension throws: Exception - if an error occurs |
unUseDatasource | protected void unUseDatasource(String datasource) throws Exception(Code) | | Unload a datasource in jonas server
Parameters: datasource - name of the datasource throws: Exception - if an error occurs |
unUseEar | public void unUseEar(String filename) throws Exception(Code) | | Unload a ear file in the jonas server
Parameters: filename - ear file, without ".ear" extension throws: Exception - if an error occurs |
undeployAll | protected void undeployAll(WebResponse wr) throws Exception(Code) | | Undeploy all
throws: Exception - if error occurs |
undeployAllEar | protected void undeployAllEar() throws Exception(Code) | | Undeploy all EAR
throws: Exception - if error occurs |
undeployAllJar | protected void undeployAllJar() throws Exception(Code) | | Undeploy all Jars
throws: Exception - if error occurs |
undeployEar | protected void undeployEar(String name) throws Exception(Code) | | Undeploy an EAR
Parameters: name - String of EAR Name throws: Exception - if error occurs |
useBeans | public void useBeans(String filename) throws Exception(Code) | | Load a bean jar file in the jonas server
Parameters: filename - jar file, without ".jar" extension throws: Exception - if an error occurs |
useDatasource | protected void useDatasource(String datasource, Properties properties) throws Exception(Code) | | Load a datasource in jonas server
Parameters: datasource - name of the datasource Parameters: properties - properties of the datasource throws: Exception - if an error occurs |
useEar | public void useEar(String filename) throws Exception(Code) | | Load an ear file in the jonas server
Parameters: filename - ear file, without ".ear" extension throws: Exception - if an error occurs |
useRar | public void useRar(String filename) throws Exception(Code) | | Load a rar file in the jonas server
Parameters: filename - rar file, without ".rar" extension throws: Exception - if an error occurs |
useWar | public void useWar(String filename) throws Exception(Code) | | Load a war file in the jonas server
Parameters: filename - war file, without ".war" extension throws: Exception - if an error occurs |
|
|