ace-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1164532 - /incubator/ace/trunk/ace-integrationtests/src/test/java/org/apache/ace/it/repositoryadmin/RepositoryAdminTest.java
Date Fri, 02 Sep 2011 13:49:29 GMT
Author: marrs
Date: Fri Sep  2 13:49:29 2011
New Revision: 1164532

URL: http://svn.apache.org/viewvc?rev=1164532&view=rev
Log:
ACE-178 Fixed the test, it was failing but for a stupid reason. It was expecting a fixed number
of headers from certain bundles. It no longer does that, but still checks for specific headers
to be present.

Modified:
    incubator/ace/trunk/ace-integrationtests/src/test/java/org/apache/ace/it/repositoryadmin/RepositoryAdminTest.java

Modified: incubator/ace/trunk/ace-integrationtests/src/test/java/org/apache/ace/it/repositoryadmin/RepositoryAdminTest.java
URL: http://svn.apache.org/viewvc/incubator/ace/trunk/ace-integrationtests/src/test/java/org/apache/ace/it/repositoryadmin/RepositoryAdminTest.java?rev=1164532&r1=1164531&r2=1164532&view=diff
==============================================================================
--- incubator/ace/trunk/ace-integrationtests/src/test/java/org/apache/ace/it/repositoryadmin/RepositoryAdminTest.java
(original)
+++ incubator/ace/trunk/ace-integrationtests/src/test/java/org/apache/ace/it/repositoryadmin/RepositoryAdminTest.java
Fri Sep  2 13:49:29 2011
@@ -69,6 +69,8 @@ import java.util.jar.Attributes;
 import java.util.jar.JarOutputStream;
 import java.util.jar.Manifest;
 
+import junit.framework.Assert;
+
 import static org.apache.ace.client.repository.RepositoryObject.PRIVATE_TOPIC_ROOT;
 import static org.apache.ace.client.repository.RepositoryObject.PUBLIC_TOPIC_ROOT;
 import static org.apache.ace.client.repository.RepositoryObject.WorkingState;
@@ -1113,11 +1115,13 @@ public class RepositoryAdminTest extends
 
         assert toDeploy.length == 3 : "We expect to find three artifacts to deploy, but we
find: " + toDeploy.length;
         DeploymentArtifact bundle1 = toDeploy[0];
-        assert bundle1.getUrl().equals(b1.getURL()) && (bundle1.getKeys().length
== 2) : "The first artifact in the list should be bundle1, but it is '" + toDeploy[0].toString()
+ "'";
+        Assert.assertEquals(b1.getURL(), bundle1.getUrl());
         DeploymentArtifact bundle2 = toDeploy[1];
-        assert bundle2.getUrl().equals(b2.getURL()) && (bundle2.getKeys().length
== 3) && bundle2.getDirective(DeploymentArtifact.DIRECTIVE_ISCUSTOMIZER).equals("true"):
"The first artifact in the list should be bundle1, but it is '" + toDeploy[0].toString() +
"'";
+        Assert.assertEquals(b2.getURL(), bundle2.getUrl());
+        Assert.assertEquals("true", bundle2.getDirective(DeploymentArtifact.DIRECTIVE_ISCUSTOMIZER));
         DeploymentArtifact artifact1 = toDeploy[2];
-        assert artifact1.getUrl().equals(a1.getURL()) && (artifact1.getKeys().length
== 2) && artifact1.getDirective(DeploymentArtifact.DIRECTIVE_KEY_PROCESSORID).equals("my.processor.pid"):
"The first artifact in the list should be bundle1, but it is '" + toDeploy[0].toString() +
"'";
+        Assert.assertEquals(a1.getURL(), artifact1.getUrl());
+        Assert.assertEquals("my.processor.pid", artifact1.getDirective(DeploymentArtifact.DIRECTIVE_KEY_PROCESSORID));
 
         cleanUp();
 



Mime
View raw message