You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ro...@apache.org on 2017/10/20 14:41:37 UTC
[sling-org-apache-sling-jcr-repository-it-resource-versioning]
08/13: Fixed failing it-resource-versioning tests.
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-jcr-repository-it-resource-versioning.git
commit 9e3f742cca14649f5e156d33df00de1ae01b53d0
Author: Tomasz Rekawek <to...@apache.org>
AuthorDate: Wed Jun 24 08:16:53 2015 +0000
Fixed failing it-resource-versioning tests.
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1687195 13f79535-47bb-0310-9956-ffa450edef68
---
pom.xml | 4 ++--
.../sling/jcr/resource/it/ResourceVersioningTest.java | 16 ++++++++--------
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/pom.xml b/pom.xml
index 080feca..0b94469 100644
--- a/pom.xml
+++ b/pom.xml
@@ -61,8 +61,8 @@
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
- <artifactId>org.apache.sling.testing.sling-mock-jackrabbit</artifactId>
- <version>0.1.3-SNAPSHOT</version>
+ <artifactId>org.apache.sling.commons.testing</artifactId>
+ <version>2.0.16</version>
<scope>test</scope>
</dependency>
<dependency>
diff --git a/src/test/java/org/apache/sling/jcr/resource/it/ResourceVersioningTest.java b/src/test/java/org/apache/sling/jcr/resource/it/ResourceVersioningTest.java
index 2589fcc..ad8e82a 100644
--- a/src/test/java/org/apache/sling/jcr/resource/it/ResourceVersioningTest.java
+++ b/src/test/java/org/apache/sling/jcr/resource/it/ResourceVersioningTest.java
@@ -86,16 +86,16 @@ public class ResourceVersioningTest {
public void getResourceOnVersionableNode() throws RepositoryException, NamingException {
Resource resource = resolver.getResource("/content/test;v='1.0'");
String prop = resource.adaptTo(ValueMap.class).get("prop", String.class);
- assertEquals("/content/test;v='1.0'", resource.getPath());
assertEquals("oldvalue", prop);
+ assertEquals("/content/test;v='1.0'", resource.getPath());
}
@Test
public void getResourceOnVersionableProperty() throws RepositoryException, NamingException {
Resource resource = resolver.getResource("/content/test/prop;v='1.0'");
String prop = resource.adaptTo(String.class);
- assertEquals("/content/test/prop;v='1.0'", resource.getPath());
assertEquals("oldvalue", prop);
+ assertEquals("/content/test/prop;v='1.0'", resource.getPath());
}
@Test
@@ -104,8 +104,8 @@ public class ResourceVersioningTest {
"/content/test;v='1.0'.html/some/suffix", "/content/test.html;v=1.0/some/suffix")) {
Resource resource = resolver.resolve(path);
String prop = resource.adaptTo(ValueMap.class).get("prop", String.class);
- assertEquals("/content/test;v='1.0'", resource.getPath());
assertEquals("oldvalue", prop);
+ assertEquals("/content/test;v='1.0'", resource.getPath());
}
}
@@ -113,40 +113,40 @@ public class ResourceVersioningTest {
public void getResourceOnVersionableDescendant() throws RepositoryException, NamingException {
Resource resource = resolver.getResource("/content/test/x/y;v='1.0'");
String prop = resource.adaptTo(ValueMap.class).get("child_prop", String.class);
- assertEquals("/content/test/x/y;v='1.0'", resource.getPath());
assertEquals("child_old_value", prop);
+ assertEquals("/content/test/x/y;v='1.0'", resource.getPath());
}
@Test
public void getResourceOnVersionableDescendantProperty() throws RepositoryException, NamingException {
Resource resource = resolver.getResource("/content/test/x/y/child_prop;v='1.0'");
String prop = resource.adaptTo(String.class);
- assertEquals("/content/test/x/y/child_prop;v='1.0'", resource.getPath());
assertEquals("child_old_value", prop);
+ assertEquals("/content/test/x/y/child_prop;v='1.0'", resource.getPath());
}
@Test
public void getChildOnVersionableResource() throws RepositoryException, NamingException {
Resource resource = resolver.getResource("/content/test;v='1.0'").getChild("x/y");
String prop = resource.adaptTo(ValueMap.class).get("child_prop", String.class);
- assertEquals("/content/test/x/y;v='1.0'", resource.getPath());
assertEquals("child_old_value", prop);
+ assertEquals("/content/test/x/y;v='1.0'", resource.getPath());
}
@Test
public void listChildrenOnVersionableResource() throws RepositoryException, NamingException {
Resource resource = resolver.getResource("/content/test/x;v='1.0'").listChildren().next();
String prop = resource.adaptTo(ValueMap.class).get("child_prop", String.class);
- assertEquals("/content/test/x/y;v='1.0'", resource.getPath());
assertEquals("child_old_value", prop);
+ assertEquals("/content/test/x/y;v='1.0'", resource.getPath());
}
@Test
public void getParentOnVersionableResource() throws RepositoryException, NamingException {
Resource resource = resolver.getResource("/content/test/x;v='1.0'").getParent();
String prop = resource.adaptTo(ValueMap.class).get("prop", String.class);
- assertEquals("/content/test", resource.getPath());
assertEquals("newvalue", prop);
+ assertEquals("/content/test", resource.getPath());
}
private void registerNamespace(String prefix, String uri) throws RepositoryException {
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.