You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ace.apache.org by br...@apache.org on 2013/05/15 22:18:32 UTC

svn commit: r1483067 - in /ace/trunk: org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/ org.apache.ace.client.repository.itest/src/org/apache/ace/it/repositoryadmin/ org.apache.ace.client.rest.itest/src/org/apache/ace/client/res...

Author: bramk
Date: Wed May 15 20:18:32 2013
New Revision: 1483067

URL: http://svn.apache.org/r1483067
Log:
ACE-289 Applied itest patch from Christian

Modified:
    ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/LogAuthenticationTest.java
    ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/ObrAuthenticationTest.java
    ace/trunk/org.apache.ace.client.repository.itest/src/org/apache/ace/it/repositoryadmin/BaseRepositoryAdminTest.java
    ace/trunk/org.apache.ace.client.rest.itest/src/org/apache/ace/client/rest/itest/RESTClientTest.java
    ace/trunk/org.apache.ace.configurator.useradmin.itest/src/org/apache/ace/it/useradminconfigurator/ConfiguratorTest.java
    ace/trunk/org.apache.ace.deployment.itest/src/org/apache/ace/it/deployment/DeploymentIntegrationTest.java
    ace/trunk/org.apache.ace.http.itest/src/org/apache/ace/it/http/ServletConfiguratorIntegrationTest.java
    ace/trunk/org.apache.ace.log.itest/src/org/apache/ace/it/log/LogIntegrationTest.java
    ace/trunk/org.apache.ace.log.server.store.itest/src/org/apache/ace/log/server/store/tests/MongoLogStoreTest.java
    ace/trunk/org.apache.ace.repository.itest/src/org/apache/ace/it/repository/RepositoryTest.java
    ace/trunk/org.apache.ace.test/src/org/apache/ace/it/ExampleTest.java
    ace/trunk/org.apache.ace.test/src/org/apache/ace/it/IntegrationTestBase.java
    ace/trunk/org.apache.ace.useradmin.ui.itest/bnd.bnd
    ace/trunk/org.apache.ace.useradmin.ui.itest/src/org/apache/ace/useradmin/ui/test/UserEditorTest.java

Modified: ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/LogAuthenticationTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/LogAuthenticationTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/LogAuthenticationTest.java (original)
+++ ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/LogAuthenticationTest.java Wed May 15 20:18:32 2013
@@ -132,7 +132,7 @@ public class LogAuthenticationTest exten
     }
 
     @Override
-    protected void after() throws Exception {
+    protected void configureAdditionalServices() throws Exception {
         String baseURL = "http://" + HOST + ":" + TestConstants.PORT;
 
         URL testURL = new URL(baseURL.concat(AUDITLOG_ENDPOINT));
@@ -156,7 +156,7 @@ public class LogAuthenticationTest exten
     /**
      * {@inheritDoc}
      */
-    protected void before() throws Exception {
+    protected void configureProvisionedServices() throws Exception {
         String baseURL = "http://" + HOST + ":" + TestConstants.PORT;
 
         getService(SessionFactory.class).createSession("test-session-ID");

Modified: ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/ObrAuthenticationTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/ObrAuthenticationTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/ObrAuthenticationTest.java (original)
+++ ace/trunk/org.apache.ace.authentication.itest/src/org/apache/ace/it/authentication/ObrAuthenticationTest.java Wed May 15 20:18:32 2013
@@ -207,7 +207,7 @@ public class ObrAuthenticationTest exten
     }
 
     @Override
-    protected void after() throws Exception {
+    protected void configureAdditionalServices() throws Exception {
         String userName = "d";
         String password = "f";
 
@@ -234,7 +234,7 @@ public class ObrAuthenticationTest exten
      * {@inheritDoc}
      */
     @Override
-    protected void before() throws Exception {
+    protected void configureProvisionedServices() throws Exception {
         m_endpoint = "/obr";
         
         String tmpDir = System.getProperty("java.io.tmpdir");

Modified: ace/trunk/org.apache.ace.client.repository.itest/src/org/apache/ace/it/repositoryadmin/BaseRepositoryAdminTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.client.repository.itest/src/org/apache/ace/it/repositoryadmin/BaseRepositoryAdminTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.client.repository.itest/src/org/apache/ace/it/repositoryadmin/BaseRepositoryAdminTest.java (original)
+++ ace/trunk/org.apache.ace.client.repository.itest/src/org/apache/ace/it/repositoryadmin/BaseRepositoryAdminTest.java Wed May 15 20:18:32 2013
@@ -185,13 +185,13 @@ public abstract class BaseRepositoryAdmi
     }
 
     @Override
-	protected void after() throws Exception {
+	protected void configureAdditionalServices() throws Exception {
         // remove all repositories, in case a test case does not reach it's cleanup section due to an exception
         removeAllRepositories();
     }
 
     @Override
-	protected void before() throws Exception {
+	protected void configureProvisionedServices() throws Exception {
         m_endpoint = new URL(HOST + ENDPOINT_NAME);
 
         getService(SessionFactory.class).createSession("test-session-ID");

Modified: ace/trunk/org.apache.ace.client.rest.itest/src/org/apache/ace/client/rest/itest/RESTClientTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.client.rest.itest/src/org/apache/ace/client/rest/itest/RESTClientTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.client.rest.itest/src/org/apache/ace/client/rest/itest/RESTClientTest.java (original)
+++ ace/trunk/org.apache.ace.client.rest.itest/src/org/apache/ace/client/rest/itest/RESTClientTest.java Wed May 15 20:18:32 2013
@@ -53,7 +53,7 @@ public class RESTClientTest extends Inte
     }
     
     @Override
-    protected void after() throws Exception {
+    protected void configureAdditionalServices() throws Exception {
         // there is some setup we only want to do once, before the first test we run, and since we cannot
         // predict which one that is, we use a static flag
         if (!m_hasBeenSetup) {

Modified: ace/trunk/org.apache.ace.configurator.useradmin.itest/src/org/apache/ace/it/useradminconfigurator/ConfiguratorTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.configurator.useradmin.itest/src/org/apache/ace/it/useradminconfigurator/ConfiguratorTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.configurator.useradmin.itest/src/org/apache/ace/it/useradminconfigurator/ConfiguratorTest.java (original)
+++ ace/trunk/org.apache.ace.configurator.useradmin.itest/src/org/apache/ace/it/useradminconfigurator/ConfiguratorTest.java Wed May 15 20:18:32 2013
@@ -78,7 +78,7 @@ public class ConfiguratorTest extends In
     }
 
     @Override
-	protected void before() throws Exception {
+	protected void configureProvisionedServices() throws Exception {
         configureFactory("org.apache.ace.server.repository.factory",
                 RepositoryConstants.REPOSITORY_NAME, "users",
                 RepositoryConstants.REPOSITORY_CUSTOMER, "apache",

Modified: ace/trunk/org.apache.ace.deployment.itest/src/org/apache/ace/it/deployment/DeploymentIntegrationTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.deployment.itest/src/org/apache/ace/it/deployment/DeploymentIntegrationTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.deployment.itest/src/org/apache/ace/it/deployment/DeploymentIntegrationTest.java (original)
+++ ace/trunk/org.apache.ace.deployment.itest/src/org/apache/ace/it/deployment/DeploymentIntegrationTest.java Wed May 15 20:18:32 2013
@@ -90,7 +90,7 @@ public class DeploymentIntegrationTest e
 //        );
 //    }
 
-    protected void before() throws IOException {
+    protected void configureProvisionedServices() throws IOException {
         m_tempDir = File.createTempFile("test", "");
         m_tempDir.delete();
         m_tempDir.mkdir();
@@ -117,7 +117,7 @@ public class DeploymentIntegrationTest e
     private ServiceRegistration m_deploymentAdminProxyRegistration;
 
     @Override
-	protected void after() throws Exception {
+	protected void configureAdditionalServices() throws Exception {
         deleteDirOrFile(m_tempDir);
     }
 

Modified: ace/trunk/org.apache.ace.http.itest/src/org/apache/ace/it/http/ServletConfiguratorIntegrationTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.http.itest/src/org/apache/ace/it/http/ServletConfiguratorIntegrationTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.http.itest/src/org/apache/ace/it/http/ServletConfiguratorIntegrationTest.java (original)
+++ ace/trunk/org.apache.ace.http.itest/src/org/apache/ace/it/http/ServletConfiguratorIntegrationTest.java Wed May 15 20:18:32 2013
@@ -72,7 +72,7 @@ public class ServletConfiguratorIntegrat
     }
 
     @Override
-	protected void before() throws Exception {
+	protected void configureProvisionedServices() throws Exception {
         m_echoServlet = new EchoServlet();
 
         Dictionary<String, String> dictionary = new Hashtable<String, String>();

Modified: ace/trunk/org.apache.ace.log.itest/src/org/apache/ace/it/log/LogIntegrationTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.log.itest/src/org/apache/ace/it/log/LogIntegrationTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.log.itest/src/org/apache/ace/it/log/LogIntegrationTest.java (original)
+++ ace/trunk/org.apache.ace.log.itest/src/org/apache/ace/it/log/LogIntegrationTest.java Wed May 15 20:18:32 2013
@@ -64,7 +64,7 @@ public class LogIntegrationTest extends 
     }
 
     @Override
-	protected void before() throws Exception {
+	protected void configureProvisionedServices() throws Exception {
         configure(DiscoveryConstants.DISCOVERY_PID,
                 DiscoveryConstants.DISCOVERY_URL_KEY, "http://" + HOST + ":" + TestConstants.PORT);
         configure(IdentificationConstants.IDENTIFICATION_PID,

Modified: ace/trunk/org.apache.ace.log.server.store.itest/src/org/apache/ace/log/server/store/tests/MongoLogStoreTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.log.server.store.itest/src/org/apache/ace/log/server/store/tests/MongoLogStoreTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.log.server.store.itest/src/org/apache/ace/log/server/store/tests/MongoLogStoreTest.java (original)
+++ ace/trunk/org.apache.ace.log.server.store.itest/src/org/apache/ace/log/server/store/tests/MongoLogStoreTest.java Wed May 15 20:18:32 2013
@@ -41,10 +41,10 @@ public class MongoLogStoreTest extends I
 	private volatile MongoDBService m_mongodbService;
 
 	@Override
-	protected void before() throws Exception {
+	protected void configureProvisionedServices() throws Exception {
 		configureFactory("org.amdatu.mongo", "dbName", "ace");
 		configureFactory("org.apache.ace.log.server.store.factory", "name", "serverlog");
-		super.before();
+		super.configureProvisionedServices();
 	}
 
 	protected org.apache.felix.dm.Component[] getDependencies() {

Modified: ace/trunk/org.apache.ace.repository.itest/src/org/apache/ace/it/repository/RepositoryTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.repository.itest/src/org/apache/ace/it/repository/RepositoryTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.repository.itest/src/org/apache/ace/it/repository/RepositoryTest.java (original)
+++ ace/trunk/org.apache.ace.repository.itest/src/org/apache/ace/it/repository/RepositoryTest.java Wed May 15 20:18:32 2013
@@ -174,7 +174,7 @@ public class RepositoryTest extends Inte
         removeRepository("testInstance");
     }
 
-    protected void before() throws IOException {
+    protected void configureProvisionedServices() throws IOException {
 		m_host = new URL("http://localhost:" + TestConstants.PORT);
 
         configure("org.apache.ace.repository.servlet.RepositoryReplicationServlet",

Modified: ace/trunk/org.apache.ace.test/src/org/apache/ace/it/ExampleTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.test/src/org/apache/ace/it/ExampleTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.test/src/org/apache/ace/it/ExampleTest.java (original)
+++ ace/trunk/org.apache.ace.test/src/org/apache/ace/it/ExampleTest.java Wed May 15 20:18:32 2013
@@ -44,7 +44,7 @@ public class ExampleTest extends Integra
 //        );
 //    }
 
-    protected void before() throws IOException {
+    protected void configureProvisionedServices() throws IOException {
         // configure the services you need; you cannot use the injected members yet
     }
 

Modified: ace/trunk/org.apache.ace.test/src/org/apache/ace/it/IntegrationTestBase.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.test/src/org/apache/ace/it/IntegrationTestBase.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.test/src/org/apache/ace/it/IntegrationTestBase.java (original)
+++ ace/trunk/org.apache.ace.test/src/org/apache/ace/it/IntegrationTestBase.java Wed May 15 20:18:32 2013
@@ -113,7 +113,7 @@ public class IntegrationTestBase extends
      * The {@link #after} callback is most useful for configuring additional services after all mandatory 
      * services are resolved.
      */
-    protected void after() throws Exception {}
+    protected void configureAdditionalServices() throws Exception {}
 
     /**
      * The 'before' callback will be called after the components from {@link #getDependencies} have been
@@ -123,7 +123,7 @@ public class IntegrationTestBase extends
      * The {@link #before} callback is most useful for configuring services that have been provisioned
      * in the 'configuration' method.
      */
-    protected void before() throws Exception {}
+    protected void configureProvisionedServices() throws Exception {}
 
     /**
      * Write configuration for a single service. For example,
@@ -328,7 +328,7 @@ public class IntegrationTestBase extends
         }
 
 		// Call back the implementation...
-		before();
+		configureProvisionedServices();
 
         // And wait for all components to come online.
         try {
@@ -336,7 +336,7 @@ public class IntegrationTestBase extends
                 fail("Not all components were started. Still missing the following:\n" + listener.componentsString());
             }
             
-        	after();
+        	configureAdditionalServices();
         }
         catch (InterruptedException e) {
             fail("Interrupted while waiting for services to get started.");

Modified: ace/trunk/org.apache.ace.useradmin.ui.itest/bnd.bnd
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.useradmin.ui.itest/bnd.bnd?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.useradmin.ui.itest/bnd.bnd (original)
+++ ace/trunk/org.apache.ace.useradmin.ui.itest/bnd.bnd Wed May 15 20:18:32 2013
@@ -1,7 +1,7 @@
 Test-Cases: ${classes;CONCRETE;EXTENDS;org.apache.ace.it.IntegrationTestBase}
 Private-Package: org.apache.ace.useradmin.ui.test
 -runvm: -ea
--runfw: org.apache.felix.framework
+-runfw: org.apache.felix.framework;version='[4.0.3,4.0.3]'
 -runbundles: \
 	osgi.cmpn,\
 	com.vaadin,\

Modified: ace/trunk/org.apache.ace.useradmin.ui.itest/src/org/apache/ace/useradmin/ui/test/UserEditorTest.java
URL: http://svn.apache.org/viewvc/ace/trunk/org.apache.ace.useradmin.ui.itest/src/org/apache/ace/useradmin/ui/test/UserEditorTest.java?rev=1483067&r1=1483066&r2=1483067&view=diff
==============================================================================
--- ace/trunk/org.apache.ace.useradmin.ui.itest/src/org/apache/ace/useradmin/ui/test/UserEditorTest.java (original)
+++ ace/trunk/org.apache.ace.useradmin.ui.itest/src/org/apache/ace/useradmin/ui/test/UserEditorTest.java Wed May 15 20:18:32 2013
@@ -39,8 +39,8 @@ public class UserEditorTest extends Inte
     }
 
     @Override
-    protected void before() throws Exception {
-        super.before();
+    protected void configureProvisionedServices() throws Exception {
+        super.configureProvisionedServices();
         if (firststart) {
             Thread.sleep(1000);
             firststart = false;