You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by cz...@apache.org on 2011/08/10 08:40:31 UTC
svn commit: r1156045 -
/sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/servlets/post/PostServletImportTest.java
Author: cziegeler
Date: Wed Aug 10 06:40:31 2011
New Revision: 1156045
URL: http://svn.apache.org/viewvc?rev=1156045&view=rev
Log:
Add more info for failing test
Modified:
sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/servlets/post/PostServletImportTest.java
Modified: sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/servlets/post/PostServletImportTest.java
URL: http://svn.apache.org/viewvc/sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/servlets/post/PostServletImportTest.java?rev=1156045&r1=1156044&r2=1156045&view=diff
==============================================================================
--- sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/servlets/post/PostServletImportTest.java (original)
+++ sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/servlets/post/PostServletImportTest.java Wed Aug 10 06:40:31 2011
@@ -118,7 +118,7 @@ public class PostServletImportTest exten
assertTrue(actualValuesSet.contains(expectedArray.get(i)));
}
} else {
- assertEquals(object, object2);
+ assertEquals("Value of key: " + key, object, object2);
}
}
}
@@ -723,7 +723,7 @@ public class PostServletImportTest exten
String testNodeName = "testNode_" + String.valueOf(random.nextInt());
props.put(SlingPostConstants.RP_NODE_NAME_HINT, testNodeName);
- String jsonContent = getStreamAsString(getClass().getResourceAsStream("/integration-test/servlets/post/testimport_utf8.json"), "UTF-8");
+ final String jsonContent = getStreamAsString(getClass().getResourceAsStream("/integration-test/servlets/post/testimport_utf8.json"), "UTF-8");
props.put(SlingPostConstants.RP_CONTENT, jsonContent);
props.put(SlingPostConstants.RP_CONTENT_TYPE, "json");
props.put(SlingPostConstants.RP_REDIRECT_TO, SERVLET_CONTEXT + testPath + "/*");
@@ -737,8 +737,7 @@ public class PostServletImportTest exten
assertNotNull(jsonObj);
//assert the imported content is there.
- String expectedJsonContent = getStreamAsString(getClass().getResourceAsStream("/integration-test/servlets/post/testimport_utf8.json"), "UTF-8");
- assertExpectedJSON(new JSONObject(expectedJsonContent), jsonObj);
+ assertExpectedJSON(new JSONObject(jsonContent), jsonObj);
}
}