You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@chemistry.apache.org by fm...@apache.org on 2013/09/13 17:08:08 UTC
svn commit: r1522966 -
/chemistry/opencmis/trunk/chemistry-opencmis-test/chemistry-opencmis-test-tck/src/main/java/org/apache/chemistry/opencmis/tck/impl/AbstractSessionTest.java
Author: fmui
Date: Fri Sep 13 15:08:07 2013
New Revision: 1522966
URL: http://svn.apache.org/r1522966
Log:
TCK: added path check
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-test/chemistry-opencmis-test-tck/src/main/java/org/apache/chemistry/opencmis/tck/impl/AbstractSessionTest.java
Modified: chemistry/opencmis/trunk/chemistry-opencmis-test/chemistry-opencmis-test-tck/src/main/java/org/apache/chemistry/opencmis/tck/impl/AbstractSessionTest.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-test/chemistry-opencmis-test-tck/src/main/java/org/apache/chemistry/opencmis/tck/impl/AbstractSessionTest.java?rev=1522966&r1=1522965&r2=1522966&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-test/chemistry-opencmis-test-tck/src/main/java/org/apache/chemistry/opencmis/tck/impl/AbstractSessionTest.java (original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-test/chemistry-opencmis-test-tck/src/main/java/org/apache/chemistry/opencmis/tck/impl/AbstractSessionTest.java Fri Sep 13 15:08:07 2013
@@ -929,6 +929,18 @@ public abstract class AbstractSessionTes
}
}
+ // special case: path
+ if (PropertyIds.PATH.equals(propId) && prop.getFirstValue() != null) {
+ Object path = prop.getFirstValue();
+ if (path instanceof String) {
+ f = createResult(FAILURE, "Path does not start with '/': " + path);
+ addResult(results,
+ assertIsTrue(((String) path).length() > 0 && ((String) path).charAt(0) == '/', null, f));
+ } else {
+ addResult(results, createResult(FAILURE, "Property " + PropertyIds.PATH + " is not a string!"));
+ }
+ }
+
// check property
addResult(results, checkProperty(prop, "Property " + propId, propertyCheck));
@@ -1796,7 +1808,7 @@ public abstract class AbstractSessionTes
}
if (property.getDefinition().isRequired() == null) {
- addResult(results, createResult(FAILURE, "Property definition doesn't contain the required flag!!"));
+ addResult(results, createResult(FAILURE, "Property definition doesn't contain the required flag!"));
} else {
if (property.getDefinition().isRequired().booleanValue()) {
f = createResult(FAILURE, "Property is required but has no value!");