Author: rhauch
Date: 2009-03-23 23:18:34 -0400 (Mon, 23 Mar 2009)
New Revision: 792
Added:
trunk/dna-jcr-tck/
trunk/dna-jcr-tck/.classpath
trunk/dna-jcr-tck/.project
trunk/dna-jcr-tck/pom.xml
trunk/dna-jcr-tck/src/
trunk/dna-jcr-tck/src/test/
trunk/dna-jcr-tck/src/test/java/
trunk/dna-jcr-tck/src/test/java/org/
trunk/dna-jcr-tck/src/test/java/org/jboss/
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/InMemoryRepositoryStub.java
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelOneTckTest.java
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelTwoTckTest.java
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalLockingTckTest.java
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalObservationTckTest.java
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalSqlQueryTckTest.java
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalVersionTckTest.java
trunk/dna-jcr-tck/src/test/resources/
trunk/dna-jcr-tck/src/test/resources/log4j.properties
trunk/dna-jcr-tck/src/test/resources/repositoryForTckTests.xml
trunk/dna-jcr-tck/src/test/resources/repositoryStubImpl.properties
Modified:
trunk/pom.xml
Log:
DNA-306 Add ability to run all TCK unit tests within Hudson, showing success and failure
rate
Applied the patch, which adds a 'dna-jcr-tck' project (which is no longer under
'extensions' but is at the top level) that shows how the project is doing relative
to the JCR TCK unit tests. These unit tests are NOT the official TCK, but are reportedly
some of the tests that comprise the TCK and are available via the Jackrabbit project.
Also changed the parent POM to include this module only when using the 'jcr-tck'
profile (e.g., 'mvn install -P jcr-tck').
Property changes on: trunk/dna-jcr-tck
___________________________________________________________________
Name: svn:ignore
+ target
Added: trunk/dna-jcr-tck/.classpath
===================================================================
--- trunk/dna-jcr-tck/.classpath (rev 0)
+++ trunk/dna-jcr-tck/.classpath 2009-03-24 03:18:34 UTC (rev 792)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" output="target/test-classes"
path="src/test/java"/>
+ <classpathentry kind="src" output="target/test-classes"
path="src/test/resources"/>
+ <classpathentry kind="con"
path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="con"
path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
Added: trunk/dna-jcr-tck/.project
===================================================================
--- trunk/dna-jcr-tck/.project (rev 0)
+++ trunk/dna-jcr-tck/.project 2009-03-24 03:18:34 UTC (rev 792)
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>dna-jcr-tck</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.wst.common.project.facet.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.maven.ide.eclipse.maven2Builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.maven.ide.eclipse.maven2Nature</nature>
+ <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
+ </natures>
+</projectDescription>
Added: trunk/dna-jcr-tck/pom.xml
===================================================================
--- trunk/dna-jcr-tck/pom.xml (rev 0)
+++ trunk/dna-jcr-tck/pom.xml 2009-03-24 03:18:34 UTC (rev 792)
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.jboss.dna</groupId>
+ <artifactId>dna</artifactId>
+ <version>0.4-SNAPSHOT</version>
+ </parent>
+ <!-- The groupId and version values are inherited from parent -->
+ <artifactId>dna-jcr-tck</artifactId>
+ <packaging>jar</packaging>
+ <name>JBoss DNA JCR Compatibility Unit Tests</name>
+ <description>JBoss DNA unit tests to check compatibility with the JCR 1.0 API.
This does NOT use the official TCK.</description>
+ <
url>http://labs.jboss.org/dna</url>
+
+ <!--
+ Define the dependencies. Note that all version and scopes default to those
+ defined in the dependencyManagement section of the parent pom.
+ -->
+ <dependencies>
+ <dependency>
+ <groupId>org.jboss.dna</groupId>
+ <artifactId>dna-common</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.dna</groupId>
+ <artifactId>dna-common</artifactId>
+ <version>${pom.version}</version>
+ <type>test-jar</type>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.dna</groupId>
+ <artifactId>dna-graph</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.dna</groupId>
+ <artifactId>dna-graph</artifactId>
+ <version>${pom.version}</version>
+ <type>test-jar</type>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.dna</groupId>
+ <artifactId>dna-repository</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.dna</groupId>
+ <artifactId>dna-jcr</artifactId>
+ <version>${pom.version}</version>
+ </dependency>
+ <!--
+ Testing (note the scope)
+ -->
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <!--
+ Logging (require SLF4J API for compiling, but use Log4J and its SLF4J binding for
testing)
+ -->
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <!--
+ Java Concurrency in Practice annotations
+ -->
+ <dependency>
+ <groupId>net.jcip</groupId>
+ <artifactId>jcip-annotations</artifactId>
+ </dependency>
+ <!--
+ Java Content Repository API
+ -->
+ <dependency>
+ <groupId>javax.jcr</groupId>
+ <artifactId>jcr</artifactId>
+ </dependency>
+ <!--
+ Apache JCR API unit tests (for any JCR implementation), which is a subset of the
official TCK
+ -->
+ <dependency>
+ <groupId>org.apache.jackrabbit</groupId>
+ <artifactId>jackrabbit-jcr-tests</artifactId>
+ </dependency>
+ </dependencies>
+</project>
\ No newline at end of file
Added: trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/InMemoryRepositoryStub.java
===================================================================
--- trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/InMemoryRepositoryStub.java
(rev 0)
+++
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/InMemoryRepositoryStub.java 2009-03-24
03:18:34 UTC (rev 792)
@@ -0,0 +1,152 @@
+/*
+ * JBoss DNA (
http://www.jboss.org/dna)
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * See the AUTHORS.txt file in the distribution for a full listing of
+ * individual contributors.
+ *
+ * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ * is licensed to you under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * JBoss DNA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.dna.jcr;
+
+import java.io.File;
+import java.net.URI;
+import java.security.AccessControlContext;
+import java.security.AccessController;
+import java.util.Collections;
+import java.util.Properties;
+import javax.jcr.Credentials;
+import javax.jcr.Repository;
+import org.apache.jackrabbit.test.RepositoryStub;
+import org.jboss.dna.graph.DnaLexicon;
+import org.jboss.dna.graph.ExecutionContext;
+import org.jboss.dna.graph.Graph;
+import org.jboss.dna.graph.GraphImporter;
+import org.jboss.dna.graph.JcrNtLexicon;
+import org.jboss.dna.graph.Location;
+import org.jboss.dna.graph.connector.RepositoryConnection;
+import org.jboss.dna.graph.connector.RepositoryConnectionFactory;
+import org.jboss.dna.graph.connector.inmemory.InMemoryRepositorySource;
+import org.jboss.dna.graph.property.Path;
+
+/**
+ * Class with TCK repository stub. This class does not contain any tests.
+ */
+public class InMemoryRepositoryStub extends RepositoryStub {
+ private Repository repository;
+ protected RepositoryConnection connection;
+ protected AccessControlContext accessControlContext = AccessController.getContext();
+
+ private Credentials credentials = new Credentials() {
+ private static final long serialVersionUID = 1L;
+
+ @SuppressWarnings( "unused" )
+ public AccessControlContext getAccessControlContext() {
+ return accessControlContext;
+ }
+ };
+
+ protected ExecutionContext executionContext = new ExecutionContext() {
+
+ @Override
+ public ExecutionContext create( AccessControlContext accessControlContext ) {
+ return executionContext;
+ }
+ };
+
+ protected RepositoryConnectionFactory connectionFactory = new
RepositoryConnectionFactory() {
+ public RepositoryConnection createConnection( String sourceName ) {
+ return connection;
+ }
+ };
+
+ public InMemoryRepositoryStub( Properties env ) {
+ super(env);
+
+ // Create the in-memory (DNA) repository
+ InMemoryRepositorySource source = new InMemoryRepositorySource();
+
+ // Various calls will fail if you do not set a non-null name for the source
+ source.setName("TestRepositorySource");
+
+ // Wrap a connection to the in-memory (DNA) repository in a (JCR) repository
+ connection = source.getConnection();
+ repository = new JcrRepository(Collections.<String, String>emptyMap(),
executionContext.create(accessControlContext),
+ connectionFactory, source.getName());
+
+ // Make sure the path to the namespaces exists ...
+ Graph graph = Graph.create(source.getName(), connectionFactory,
executionContext);
+
graph.create("/jcr:system").and().create("/jcr:system/dna:namespaces");
+
+ // Set up some sample nodes in the graph to match the expected test
configuration
+ try {
+
+ // TODO: Should there be an easier way to define these since they will be
needed for all JCR repositories?
+ executionContext.getNamespaceRegistry().register(DnaLexicon.Namespace.PREFIX,
DnaLexicon.Namespace.URI);
+ executionContext.getNamespaceRegistry().register(JcrLexicon.Namespace.PREFIX,
JcrLexicon.Namespace.URI);
+
executionContext.getNamespaceRegistry().register(JcrNtLexicon.Namespace.PREFIX,
JcrNtLexicon.Namespace.URI);
+ executionContext.getNamespaceRegistry().register("sv",
"http://www.jcp.org/jcr/sv/1.0");
+
+ Path destinationPath =
executionContext.getValueFactories().getPathFactory().create("/");
+ GraphImporter importer = new GraphImporter(graph);
+
+ URI xmlContent = new
File("src/test/resources/repositoryForTckTests.xml").toURI();
+ Graph.Batch batch = importer.importXml(xmlContent,
Location.create(destinationPath));
+ batch.execute();
+
+ } catch (Exception ex) {
+ // The TCK tries to quash this exception. Print it out to be more obvious.
+ ex.printStackTrace();
+ throw new IllegalStateException("Repository initialization
failed.", ex);
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ *
+ * @see org.apache.jackrabbit.test.RepositoryStub#getSuperuserCredentials()
+ */
+ @Override
+ public Credentials getSuperuserCredentials() {
+ // TODO: Why must we override this method? The default TCK implementation just
returns a particular instance of
+ // SimpleCredentials.
+ return credentials;
+ }
+
+ /**
+ * {@inheritDoc}
+ *
+ * @see org.apache.jackrabbit.test.RepositoryStub#getReadOnlyCredentials()
+ */
+ @Override
+ public Credentials getReadOnlyCredentials() {
+ // TODO: Why must we override this method? The default TCK implementation just
returns a particular instance of
+ // SimpleCredentials.
+ return credentials;
+ }
+
+ /**
+ * {@inheritDoc}
+ *
+ * @see org.apache.jackrabbit.test.RepositoryStub#getRepository()
+ */
+ @Override
+ public Repository getRepository() {
+ return repository;
+ }
+
+}
Added: trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelOneTckTest.java
===================================================================
--- trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelOneTckTest.java
(rev 0)
+++
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelOneTckTest.java 2009-03-24
03:18:34 UTC (rev 792)
@@ -0,0 +1,127 @@
+/*
+ * JBoss DNA (
http://www.jboss.org/dna)
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * See the AUTHORS.txt file in the distribution for a full listing of
+ * individual contributors.
+ *
+ * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ * is licensed to you under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * JBoss DNA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.dna.jcr;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import org.apache.jackrabbit.test.JCRTestSuite;
+
+/**
+ * Test suite to wrap Apache Jackrabbit JCR technology compatibility kit (TCK) unit tests
for Level 1 (L1) compliance. Note that
+ * technically these are not the actual TCK, but these are unit tests that happen to be
similar to (or provided the basis for) a
+ * subset of the TCK.
+ */
+public class Jsr170LevelOneTckTest {
+
+ /**
+ *
+ */
+ public Jsr170LevelOneTckTest() {
+ }
+
+ /**
+ * Wrapper so that the Jackrabbit TCK test suite gets picked up by the DNA Maven test
target.
+ *
+ * @return a new instance of {@link JCRTestSuite}.
+ */
+ public static Test suite() {
+ // Uncomment this to execute all tests
+ // return new JCRTestSuite();
+
+ // Or uncomment the following lines to execute the different sets/suites of tests
...
+ TestSuite suite = new TestSuite("JCR 1.0 Level 1 Compliance tests");
+
+ suite.addTest(new LevelOneFeatureTests());
+
+ return suite;
+ }
+
+ /**
+ * Test suite that includes the Level 1 JCR TCK API tests from the Jackrabbit
project.
+ */
+ private static class LevelOneFeatureTests extends TestSuite {
+ protected LevelOneFeatureTests() {
+ super("JCR Level 1 API Tests");
+ // We currently don't pass the tests in those suites that are commented
out
+ // See
https://jira.jboss.org/jira/browse/DNA-285
+
+ addTestSuite(org.apache.jackrabbit.test.api.RootNodeTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.NodeReadMethodsTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.PropertyTypeTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.NodeDiscoveringNodeTypesTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.BinaryPropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.BooleanPropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.DatePropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.DoublePropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.LongPropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.NamePropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.PathPropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.ReferencePropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.StringPropertyTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.UndefinedPropertyTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.NamespaceRegistryReadMethodsTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.NamespaceRemappingTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.NodeIteratorTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.PropertyReadMethodsTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.RepositoryDescriptorTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.SessionReadMethodsTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.WorkspaceReadMethodsTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.ReferenceableRootNodesTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.ExportSysViewTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.ExportDocViewTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.RepositoryLoginTest.class);
+
+ // These might not all be level one tests
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathPosIndexTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathDocOrderTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathOrderByTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathJcrPathTest.class);
+
+ addTestSuite(org.apache.jackrabbit.test.api.query.ElementTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.OrderByDateTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.OrderByDoubleTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.OrderByLongTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.query.OrderByMultiTypeTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.OrderByStringTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.query.QueryResultNodeIteratorTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathDocOrderTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathJcrPathTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathOrderByTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.XPathPosIndexTest.class);
+
+
addTestSuite(org.apache.jackrabbit.test.api.query.DerefQueryLevel1Test.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.GetLanguageTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.query.GetPersistentQueryPathLevel1Test.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.GetStatementTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.query.GetSupportedQueryLanguagesTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.query.GetPropertyNamesTest.class);
+ addTestSuite(org.apache.jackrabbit.test.api.query.PredicatesTest.class);
+
addTestSuite(org.apache.jackrabbit.test.api.query.SimpleSelectionTest.class);
+
+ // The tests in this suite are level one
+ addTest(org.apache.jackrabbit.test.api.nodetype.TestAll.suite());
+ }
+ }
+
+}
Added: trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelTwoTckTest.java
===================================================================
--- trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelTwoTckTest.java
(rev 0)
+++
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170LevelTwoTckTest.java 2009-03-24
03:18:34 UTC (rev 792)
@@ -0,0 +1,196 @@
+/*
+ * JBoss DNA (
http://www.jboss.org/dna)
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * See the AUTHORS.txt file in the distribution for a full listing of
+ * individual contributors.
+ *
+ * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ * is licensed to you under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * JBoss DNA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.dna.jcr;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import org.apache.jackrabbit.test.JCRTestSuite;
+import org.apache.jackrabbit.test.api.AddNodeTest;
+import org.apache.jackrabbit.test.api.CheckPermissionTest;
+import org.apache.jackrabbit.test.api.DocumentViewImportTest;
+import org.apache.jackrabbit.test.api.ImpersonateTest;
+import org.apache.jackrabbit.test.api.NamespaceRegistryTest;
+import org.apache.jackrabbit.test.api.NodeAddMixinTest;
+import org.apache.jackrabbit.test.api.NodeCanAddMixinTest;
+import org.apache.jackrabbit.test.api.NodeItemIsModifiedTest;
+import org.apache.jackrabbit.test.api.NodeItemIsNewTest;
+import org.apache.jackrabbit.test.api.NodeOrderableChildNodesTest;
+import org.apache.jackrabbit.test.api.NodeRemoveMixinTest;
+import org.apache.jackrabbit.test.api.NodeTest;
+import org.apache.jackrabbit.test.api.NodeUUIDTest;
+import org.apache.jackrabbit.test.api.PropertyItemIsModifiedTest;
+import org.apache.jackrabbit.test.api.PropertyItemIsNewTest;
+import org.apache.jackrabbit.test.api.PropertyTest;
+import org.apache.jackrabbit.test.api.ReferencesTest;
+import org.apache.jackrabbit.test.api.RepositoryLoginTest;
+import org.apache.jackrabbit.test.api.SerializationTest;
+import org.apache.jackrabbit.test.api.SessionTest;
+import org.apache.jackrabbit.test.api.SessionUUIDTest;
+import org.apache.jackrabbit.test.api.SetPropertyAssumeTypeTest;
+import org.apache.jackrabbit.test.api.SetPropertyBooleanTest;
+import org.apache.jackrabbit.test.api.SetPropertyCalendarTest;
+import org.apache.jackrabbit.test.api.SetPropertyConstraintViolationExceptionTest;
+import org.apache.jackrabbit.test.api.SetPropertyDoubleTest;
+import org.apache.jackrabbit.test.api.SetPropertyInputStreamTest;
+import org.apache.jackrabbit.test.api.SetPropertyLongTest;
+import org.apache.jackrabbit.test.api.SetPropertyNodeTest;
+import org.apache.jackrabbit.test.api.SetPropertyStringTest;
+import org.apache.jackrabbit.test.api.SetPropertyValueTest;
+import org.apache.jackrabbit.test.api.SetValueBinaryTest;
+import org.apache.jackrabbit.test.api.SetValueBooleanTest;
+import org.apache.jackrabbit.test.api.SetValueConstraintViolationExceptionTest;
+import org.apache.jackrabbit.test.api.SetValueDateTest;
+import org.apache.jackrabbit.test.api.SetValueDoubleTest;
+import org.apache.jackrabbit.test.api.SetValueLongTest;
+import org.apache.jackrabbit.test.api.SetValueReferenceTest;
+import org.apache.jackrabbit.test.api.SetValueStringTest;
+import org.apache.jackrabbit.test.api.SetValueValueFormatExceptionTest;
+import org.apache.jackrabbit.test.api.SetValueVersionExceptionTest;
+import org.apache.jackrabbit.test.api.ValueFactoryTest;
+import org.apache.jackrabbit.test.api.WorkspaceCloneReferenceableTest;
+import org.apache.jackrabbit.test.api.WorkspaceCloneSameNameSibsTest;
+import org.apache.jackrabbit.test.api.WorkspaceCloneTest;
+import org.apache.jackrabbit.test.api.WorkspaceCloneVersionableTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopyBetweenWorkspacesReferenceableTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopyBetweenWorkspacesSameNameSibsTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopyBetweenWorkspacesTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopyBetweenWorkspacesVersionableTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopyReferenceableTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopySameNameSibsTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopyTest;
+import org.apache.jackrabbit.test.api.WorkspaceCopyVersionableTest;
+import org.apache.jackrabbit.test.api.WorkspaceMoveReferenceableTest;
+import org.apache.jackrabbit.test.api.WorkspaceMoveSameNameSibsTest;
+import org.apache.jackrabbit.test.api.WorkspaceMoveTest;
+import org.apache.jackrabbit.test.api.WorkspaceMoveVersionableTest;
+import org.apache.jackrabbit.test.api.query.GetPersistentQueryPathTest;
+import org.apache.jackrabbit.test.api.query.SaveTest;
+import org.apache.jackrabbit.test.api.query.XPathQueryLevel2Test;
+
+/**
+ * Test suite to wrap Apache Jackrabbit JCR technology compatibility kit (TCK) unit tests
for Level 2 (L2) compliance. Note that
+ * technically these are not the actual TCK, but these are unit tests that happen to be
similar to (or provided the basis for) a
+ * subset of the TCK.
+ */
+public class Jsr170LevelTwoTckTest {
+
+ /**
+ *
+ */
+ public Jsr170LevelTwoTckTest() {
+ }
+
+ /**
+ * Wrapper so that the Jackrabbit TCK test suite gets picked up by the DNA Maven test
target.
+ *
+ * @return a new instance of {@link JCRTestSuite}.
+ */
+ public static Test suite() {
+ TestSuite suite = new TestSuite("JCR 1.0 Level 2 Compliance tests");
+
+ suite.addTest(new LevelTwoFeatureTests());
+
+ return suite;
+ }
+
+ /**
+ * Test suite that includes the Level 2 JCR TCK API tests from the Jackrabbit
project.
+ */
+ private static class LevelTwoFeatureTests extends TestSuite {
+ protected LevelTwoFeatureTests() {
+ super("JCR Level 2 API Tests");
+ addTestSuite(AddNodeTest.class);
+ addTestSuite(NamespaceRegistryTest.class);
+ addTestSuite(ReferencesTest.class);
+ addTestSuite(SessionTest.class);
+ addTestSuite(SessionUUIDTest.class);
+ addTestSuite(NodeTest.class);
+ addTestSuite(NodeUUIDTest.class);
+ addTestSuite(NodeOrderableChildNodesTest.class);
+ addTestSuite(PropertyTest.class);
+
+ addTestSuite(SetValueBinaryTest.class);
+ addTestSuite(SetValueBooleanTest.class);
+ addTestSuite(SetValueDateTest.class);
+ addTestSuite(SetValueDoubleTest.class);
+ addTestSuite(SetValueLongTest.class);
+ addTestSuite(SetValueReferenceTest.class);
+ addTestSuite(SetValueStringTest.class);
+ addTestSuite(SetValueConstraintViolationExceptionTest.class);
+ addTestSuite(SetValueValueFormatExceptionTest.class);
+ addTestSuite(SetValueVersionExceptionTest.class);
+
+ addTestSuite(SetPropertyBooleanTest.class);
+ addTestSuite(SetPropertyCalendarTest.class);
+ addTestSuite(SetPropertyDoubleTest.class);
+ addTestSuite(SetPropertyInputStreamTest.class);
+ addTestSuite(SetPropertyLongTest.class);
+ addTestSuite(SetPropertyNodeTest.class);
+ addTestSuite(SetPropertyStringTest.class);
+ addTestSuite(SetPropertyValueTest.class);
+ addTestSuite(SetPropertyConstraintViolationExceptionTest.class);
+ addTestSuite(SetPropertyAssumeTypeTest.class);
+
+ addTestSuite(NodeItemIsModifiedTest.class);
+ addTestSuite(NodeItemIsNewTest.class);
+ addTestSuite(PropertyItemIsModifiedTest.class);
+ addTestSuite(PropertyItemIsNewTest.class);
+
+ addTestSuite(NodeAddMixinTest.class);
+ addTestSuite(NodeCanAddMixinTest.class);
+ addTestSuite(NodeRemoveMixinTest.class);
+
+ addTestSuite(WorkspaceCloneReferenceableTest.class);
+ addTestSuite(WorkspaceCloneSameNameSibsTest.class);
+ addTestSuite(WorkspaceCloneTest.class);
+ addTestSuite(WorkspaceCloneVersionableTest.class);
+ addTestSuite(WorkspaceCopyBetweenWorkspacesReferenceableTest.class);
+ addTestSuite(WorkspaceCopyBetweenWorkspacesSameNameSibsTest.class);
+ addTestSuite(WorkspaceCopyBetweenWorkspacesTest.class);
+ addTestSuite(WorkspaceCopyBetweenWorkspacesVersionableTest.class);
+ addTestSuite(WorkspaceCopyReferenceableTest.class);
+ addTestSuite(WorkspaceCopySameNameSibsTest.class);
+ addTestSuite(WorkspaceCopyTest.class);
+ addTestSuite(WorkspaceCopyVersionableTest.class);
+ addTestSuite(WorkspaceMoveReferenceableTest.class);
+ addTestSuite(WorkspaceMoveSameNameSibsTest.class);
+ addTestSuite(WorkspaceMoveTest.class);
+ addTestSuite(WorkspaceMoveVersionableTest.class);
+
+ addTestSuite(RepositoryLoginTest.class);
+ addTestSuite(ImpersonateTest.class);
+ addTestSuite(CheckPermissionTest.class);
+
+ addTestSuite(DocumentViewImportTest.class);
+ addTestSuite(SerializationTest.class);
+
+ addTestSuite(ValueFactoryTest.class);
+
+ addTestSuite(GetPersistentQueryPathTest.class);
+ addTestSuite(SaveTest.class);
+ addTestSuite(XPathQueryLevel2Test.class);
+
+ }
+ }
+}
Added:
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalLockingTckTest.java
===================================================================
--- trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalLockingTckTest.java
(rev 0)
+++
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalLockingTckTest.java 2009-03-24
03:18:34 UTC (rev 792)
@@ -0,0 +1,67 @@
+/*
+ * JBoss DNA (
http://www.jboss.org/dna)
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * See the AUTHORS.txt file in the distribution for a full listing of
+ * individual contributors.
+ *
+ * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ * is licensed to you under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * JBoss DNA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.dna.jcr;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import org.apache.jackrabbit.test.JCRTestSuite;
+
+/**
+ * Test suite to wrap Apache Jackrabbit JCR technology compatibility kit (TCK) unit tests
for the compliance of the optional
+ * locking feature. Note that technically these are not the actual TCK, but these are
unit tests that happen to be similar to (or
+ * provided the basis for) a subset of the TCK.
+ */
+public class Jsr170OptionalLockingTckTest {
+
+ /**
+ *
+ */
+ public Jsr170OptionalLockingTckTest() {
+ }
+
+ /**
+ * Wrapper so that the Jackrabbit TCK test suite gets picked up by the DNA Maven test
target.
+ *
+ * @return a new instance of {@link JCRTestSuite}.
+ */
+ public static Test suite() {
+ TestSuite suite = new TestSuite("JCR 1.0 Optional Feature (Locking)
Compliance tests");
+
+ suite.addTest(new OptionalLockingFeatureTests());
+
+ return suite;
+ }
+
+ /**
+ * Test suite for the locking tests
+ */
+ private static class OptionalLockingFeatureTests extends TestSuite {
+ protected OptionalLockingFeatureTests() {
+ super("JCR Optional Feature (Locking) Tests");
+
+ addTest(org.apache.jackrabbit.test.api.lock.TestAll.suite());
+ }
+ }
+
+}
Added:
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalObservationTckTest.java
===================================================================
---
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalObservationTckTest.java
(rev 0)
+++
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalObservationTckTest.java 2009-03-24
03:18:34 UTC (rev 792)
@@ -0,0 +1,67 @@
+/*
+ * JBoss DNA (
http://www.jboss.org/dna)
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * See the AUTHORS.txt file in the distribution for a full listing of
+ * individual contributors.
+ *
+ * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ * is licensed to you under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * JBoss DNA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.dna.jcr;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import org.apache.jackrabbit.test.JCRTestSuite;
+
+/**
+ * Test suite to wrap Apache Jackrabbit JCR technology compatibility kit (TCK) unit tests
for the compliance of the optional
+ * observation feature. Note that technically these are not the actual TCK, but these are
unit tests that happen to be similar to (or
+ * provided the basis for) a subset of the TCK.
+ */
+public class Jsr170OptionalObservationTckTest {
+
+ /**
+ *
+ */
+ public Jsr170OptionalObservationTckTest() {
+ }
+
+ /**
+ * Wrapper so that the Jackrabbit TCK test suite gets picked up by the DNA Maven test
target.
+ *
+ * @return a new instance of {@link JCRTestSuite}.
+ */
+ public static Test suite() {
+ TestSuite suite = new TestSuite("JCR 1.0 Optional Feature (Observation)
Compliance tests");
+
+ suite.addTest(new OptionalObservationFeatureTests());
+
+ return suite;
+ }
+
+ /**
+ * Test suite for the observation tests
+ */
+ private static class OptionalObservationFeatureTests extends TestSuite {
+ protected OptionalObservationFeatureTests() {
+ super("JCR Optional Feature (Observation) Tests");
+
+ addTest(org.apache.jackrabbit.test.api.observation.TestAll.suite());
+ }
+ }
+
+}
Added:
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalSqlQueryTckTest.java
===================================================================
--- trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalSqlQueryTckTest.java
(rev 0)
+++
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalSqlQueryTckTest.java 2009-03-24
03:18:34 UTC (rev 792)
@@ -0,0 +1,76 @@
+/*
+ * JBoss DNA (
http://www.jboss.org/dna)
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * See the AUTHORS.txt file in the distribution for a full listing of
+ * individual contributors.
+ *
+ * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ * is licensed to you under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * JBoss DNA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.dna.jcr;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import org.apache.jackrabbit.test.JCRTestSuite;
+import org.apache.jackrabbit.test.api.query.SQLJcrPathTest;
+import org.apache.jackrabbit.test.api.query.SQLJoinTest;
+import org.apache.jackrabbit.test.api.query.SQLOrderByTest;
+import org.apache.jackrabbit.test.api.query.SQLPathTest;
+import org.apache.jackrabbit.test.api.query.SQLQueryLevel2Test;
+
+/**
+ * Test suite to wrap Apache Jackrabbit JCR technology compatibility kit (TCK) unit tests
for the compliance of the optional
+ * JCR-SQL query feature. Note that technically these are not the actual TCK, but these
are unit tests that happen to be similar
+ * to (or provided the basis for) a subset of the TCK.
+ */
+public class Jsr170OptionalSqlQueryTckTest {
+
+ /**
+ *
+ */
+ public Jsr170OptionalSqlQueryTckTest() {
+ }
+
+ /**
+ * Wrapper so that the Jackrabbit TCK test suite gets picked up by the DNA Maven test
target.
+ *
+ * @return a new instance of {@link JCRTestSuite}.
+ */
+ public static Test suite() {
+ TestSuite suite = new TestSuite("JCR 1.0 Optional Feature (JCR-SQL Query)
Compliance tests");
+
+ suite.addTest(new OptionalSqlQueryFeatureTests());
+
+ return suite;
+ }
+
+ /**
+ * Test suite for the JCR-SQL query tests
+ */
+ private static class OptionalSqlQueryFeatureTests extends TestSuite {
+ protected OptionalSqlQueryFeatureTests() {
+ super("JCR Optional Feature (JCR-SQL Query) Tests");
+
+ addTestSuite(SQLOrderByTest.class);
+ addTestSuite(SQLQueryLevel2Test.class);
+ addTestSuite(SQLJoinTest.class);
+ addTestSuite(SQLJcrPathTest.class);
+ addTestSuite(SQLPathTest.class);
+ }
+ }
+
+}
Added:
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalVersionTckTest.java
===================================================================
--- trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalVersionTckTest.java
(rev 0)
+++
trunk/dna-jcr-tck/src/test/java/org/jboss/dna/jcr/Jsr170OptionalVersionTckTest.java 2009-03-24
03:18:34 UTC (rev 792)
@@ -0,0 +1,67 @@
+/*
+ * JBoss DNA (
http://www.jboss.org/dna)
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership. Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * See the AUTHORS.txt file in the distribution for a full listing of
+ * individual contributors.
+ *
+ * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ * is licensed to you under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * JBoss DNA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.dna.jcr;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import org.apache.jackrabbit.test.JCRTestSuite;
+
+/**
+ * Test suite to wrap Apache Jackrabbit JCR technology compatibility kit (TCK) unit tests
for the compliance of the optional
+ * version feature. Note that technically these are not the actual TCK, but these are
unit tests that happen to be similar to (or
+ * provided the basis for) a subset of the TCK.
+ */
+public class Jsr170OptionalVersionTckTest {
+
+ /**
+ *
+ */
+ public Jsr170OptionalVersionTckTest() {
+ }
+
+ /**
+ * Wrapper so that the Jackrabbit TCK test suite gets picked up by the DNA Maven test
target.
+ *
+ * @return a new instance of {@link JCRTestSuite}.
+ */
+ public static Test suite() {
+ TestSuite suite = new TestSuite("JCR 1.0 Optional Feature (Version)
Compliance tests");
+
+ suite.addTest(new OptionalVersionFeatureTests());
+
+ return suite;
+ }
+
+ /**
+ * Test suite for the version tests.
+ */
+ private static class OptionalVersionFeatureTests extends TestSuite {
+ protected OptionalVersionFeatureTests() {
+ super("JCR Optional Feature (Version) Tests");
+
+ addTest(org.apache.jackrabbit.test.api.version.TestAll.suite());
+ }
+ }
+
+}
Added: trunk/dna-jcr-tck/src/test/resources/log4j.properties
===================================================================
--- trunk/dna-jcr-tck/src/test/resources/log4j.properties (rev 0)
+++ trunk/dna-jcr-tck/src/test/resources/log4j.properties 2009-03-24 03:18:34 UTC (rev
792)
@@ -0,0 +1,12 @@
+# Direct log messages to stdout
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.Target=System.out
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %m%n
+
+# Root logger option
+log4j.rootLogger=INFO, stdout
+
+# Set up the default logging to be INFO level, then override specific units
+log4j.logger.org.jboss.dna=INFO
+
Added: trunk/dna-jcr-tck/src/test/resources/repositoryForTckTests.xml
===================================================================
--- trunk/dna-jcr-tck/src/test/resources/repositoryForTckTests.xml
(rev 0)
+++ trunk/dna-jcr-tck/src/test/resources/repositoryForTckTests.xml 2009-03-24 03:18:34 UTC
(rev 792)
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ ~ JBoss DNA (
http://www.jboss.org/dna)
+ ~
+ ~ See the COPYRIGHT.txt file distributed with this work for information
+ ~ regarding copyright ownership. Some portions may be licensed
+ ~ to Red Hat, Inc. under one or more contributor license agreements.
+ ~ See the AUTHORS.txt file in the distribution for a full listing of
+ ~ individual contributors.
+ ~
+ ~ JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
+ ~ is licensed to you under the terms of the GNU Lesser General Public License as
+ ~ published by the Free Software Foundation; either version 2.1 of
+ ~ the License, or (at your option) any later version.
+ ~
+ ~ JBoss DNA is distributed in the hope that it will be useful,
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ ~ or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
+ ~ for more details.
+ ~
+ ~ You should have received a copy of the GNU Lesser General Public License
+ ~ along with this distribution; if not, write to:
+ ~ Free Software Foundation, Inc.
+ ~ 51 Franklin Street, Fifth Floor
+ ~ Boston, MA 02110-1301 USA
+ -->
+<testroot
xmlns:jcr="http://www.jcp.org/jcr/1.0"
+
xmlns:nt="http://www.jcp.org/jcr/nt/1.0"
+
xmlns:dna="http://www.jboss.org/dna/1.0"
+ jcr:primaryType="nt:unstructured">
+ <nt:unstructured jcr:name="node1"
prop1="<foo&foo>" >
+ <!--
+ This stanza checks for the jcr:xmltext special case for export as per JCR
1.0.1 section 6.4.2.3
+ -->
+ <nt:unstructured jcr:name="jcr:xmltext" jcr:xmlcharacters="This
is my "XML" text!" />
+ </nt:unstructured>
+ <nt:unstructured jcr:name="node2 has a multi-word name"
multi-valued-property="bar baz blah">
+ <!--
+ This stanza checks that consecutive jcr:xmltext elements will be merged in the
export as
+ per JCR 1.0.1 section 6.4.2.3
+ -->
+ <nt:unstructured jcr:name="jcr:xmltext" jcr:xmlcharacters="This
is my "XML" text!" />
+ <nt:unstructured jcr:name="jcr:xmltext" jcr:xmlcharacters="This
is my "other" text!" />
+ </nt:unstructured>
+ <!--
+ Test of unprintable character exports.
+ Cannot test \r character here on Windows as TCK XML Parser will replace it with \n
and fail the comparison
+ -->
+ <nt:unstructured jcr:name="node3"
multi-line-property="Line	1
Line 2"/>
+
+ <!-- Helps test date property conversion, mandatory properties (jcr:content), and
primary items -->
+ <!--
+ <nt:folder jcr:name="hierarchyRoot"
jcr:created="+2009-03-15T12:30:00.000Z">
+ <nt:file jcr:name="testFile"
jcr:created="+2009-03-15T13:30:00.000Z">
+ <nt:unstructured jcr:name="jcr:content" />
+ </nt:file>
+ </nt:folder>
+ -->
+</testroot>
\ No newline at end of file
Added: trunk/dna-jcr-tck/src/test/resources/repositoryStubImpl.properties
===================================================================
--- trunk/dna-jcr-tck/src/test/resources/repositoryStubImpl.properties
(rev 0)
+++ trunk/dna-jcr-tck/src/test/resources/repositoryStubImpl.properties 2009-03-24 03:18:34
UTC (rev 792)
@@ -0,0 +1,9 @@
+javax.jcr.tck.repository_stub_impl=org.jboss.dna.jcr.InMemoryRepositoryStub
+javax.jcr.tck.testroot=/testroot
+javax.jcr.tck.nodename1=node1
+javax.jcr.tck.nodename2=node2
+javax.jcr.tck.nodename3=node3
+javax.jcr.tck.nodename4=node4
+javax.jcr.tck.propertyname1=prop1
+javax.jcr.tck.propertyname2=prop2
+javax.jcr.tck.workspacename=
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2009-03-24 02:51:24 UTC (rev 791)
+++ trunk/pom.xml 2009-03-24 03:18:34 UTC (rev 792)
@@ -142,10 +142,16 @@
<id>release</id>
<modules>
<module>docs</module>
- <module>docs/examples/gettingstarted</module>
+ <module>docs/examples/gettingstarted</module>
</modules>
</profile>
<profile>
+ <id>jcr-tck</id>
+ <modules>
+ <module>dna-jcr-tck</module>
+ </modules>
+ </profile>
+ <profile>
<!--
This profile is activated when the "generate.docs" property is set,
as in "mvn ... -Dgenerate.docs=true ..."