Class RestoreTest
- java.lang.Object
-
- junit.framework.Assert
-
- junit.framework.TestCase
-
- org.apache.jackrabbit.test.JUnitTest
-
- org.apache.jackrabbit.test.AbstractJCRTest
-
- org.apache.jackrabbit.test.api.version.AbstractVersionTest
-
- org.apache.jackrabbit.test.api.version.RestoreTest
-
- All Implemented Interfaces:
junit.framework.Test
public class RestoreTest extends AbstractVersionTest
RestoreTestcovers tests related to the restore methods available onNode:
-
-
Field Summary
-
Fields inherited from class org.apache.jackrabbit.test.api.version.AbstractVersionTest
nonVersionableNode, nonVersionableNodeType, propertyValue, versionableNode, versionableNodeType
-
Fields inherited from class org.apache.jackrabbit.test.AbstractJCRTest
isReadOnly, jcrBaseVersion, jcrCopiedFrom, jcrCreated, jcrFrozenNode, jcrFrozenUuid, jcrIsCheckedOut, jcrlockIsDeep, jcrLockOwner, jcrMergeFailed, jcrMixinTypes, jcrPredecessors, jcrPrimaryType, jcrRootVersion, jcrSuccessors, jcrSystem, jcrUUID, jcrVersionHistory, mixLockable, mixReferenceable, mixShareable, mixSimpleVersionable, mixTitle, mixVersionable, nodeName1, nodeName2, nodeName3, nodeName4, NS_JCR_URI, NS_MIX_URI, NS_NT_URI, NS_SV_URI, ntActivity, ntBase, ntFrozenNode, ntQuery, ntUnstructured, ntVersion, ntVersionHistory, ntVersionLabels, propertyName1, propertyName2, superuser, testNodeType, testNodeTypeNoChildren, testNodeTypeTestRoot, testPath, testRoot, testRootNode, vf, workspaceName
-
-
Constructor Summary
Constructors Constructor Description RestoreTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidsetUp()protected voidtearDown()voidtestRestoreChild1()voidtestRestoreChild1Jcr2()voidtestRestoreChild1Jcr2_2()voidtestRestoreChild1Jcr2_3()voidtestRestoreChild1Jcr2_4()voidtestRestoreCorrectProperty()Test if restoring a node restores the correct propertyvoidtestRestoreCorrectPropertyJcr2()Test if restoring a node restores the correct propertyvoidtestRestoreCorrectPropertyJcr2_2()Test if restoring a node restores the correct propertyvoidtestRestoreCorrectPropertyJcr2_3()Test if restoring a node restores the correct propertyvoidtestRestoreCorrectPropertyJcr2_4()Test if restoring a node restores the correct propertyvoidtestRestoreInvalidVersion()VersionException expected on Node.restore(Version, boolean) if the specified version is not part of this node's version history.voidtestRestoreInvalidVersion2()VersionException expected on Node.restore(String, boolean) if the specified version is not part of this node's version history.voidtestRestoreInvalidVersion2Jcr2()VersionException expected on Node.restore(String, boolean) if the specified version is not part of this node's version history.voidtestRestoreInvalidVersionJcr2()VersionException expected on Node.restore(Version, boolean) if the specified version is not part of this node's version history.voidtestRestoreLabel()Test the restore of a versionable node using a label.voidtestRestoreLabelJcr2()Test the restore of a versionable node using a label.voidtestRestoreName()Test the restore of the OPV=Version child nodes.voidtestRestoreNameJcr2()Test the restore of the OPV=Version child nodes.voidtestRestoreNonVersionableNode()Test calling Node.restore(String, boolean) on a non-versionable node.voidtestRestoreNonVersionableNode2()Test calling Node.restore(Version, String, boolean) on a non-versionable node.voidtestRestoreNonVersionableNode3()Test calling Node.restore(Version, boolean) on a non-versionable node.voidtestRestoreNonVersionableNode3Jcr2_2()Test restoring on a non-versionable node.voidtestRestoreNonVersionableNodeJcr2_2()Test restoring on a non-versionable node.voidtestRestoreOnCheckedInNode()Test if restoring a node works on checked-in node.voidtestRestoreOnCheckedInNodeJcr2_1()Test if restoring a node works on checked-in node.voidtestRestoreOnCheckedInNodeJcr2_2()Test if restoring a node works on checked-in node.voidtestRestoreOnCheckedInNodeJcr2_3()Test if restoring a node works on checked-in node.voidtestRestoreOnCheckedInNodeJcr2_4()Test if restoring a node works on checked-in node.voidtestRestoreOnCheckedOutNode()Test if restoring a node works on checked-out node.voidtestRestoreOnCheckedOutNodeJcr2()Test if restoring a node works on checked-out node.voidtestRestoreOnCheckedOutNodeJcr2_2()Test if restoring a node works on checked-out node.voidtestRestoreOnCheckedOutNodeJcr2_3()Test if restoring a node works on checked-out node.voidtestRestoreOnCheckedOutNodeJcr2_4()Test if restoring a node works on checked-out node.voidtestRestoreOrder()Test the child ordering of restored nodes.voidtestRestoreOrder2()Test the child ordering of restored nodes.voidtestRestoreOrder2Jcr2()Test the child ordering of restored nodes.voidtestRestoreOrder2Jcr2_2()Test the child ordering of restored nodes.voidtestRestoreOrder2Jcr2_3()Test the child ordering of restored nodes.voidtestRestoreOrder2Jcr2_4()Test the child ordering of restored nodes.voidtestRestoreOrderJcr2()Test the child ordering of restored nodes.voidtestRestoreOrderJcr2_2()Test the child ordering of restored nodes.voidtestRestoreOrderJcr2_3()Test the child ordering of restored nodes.voidtestRestoreOrderJcr2_4()Test the child ordering of restored nodes.voidtestRestoreRemoved()voidtestRestoreRemovedJcr2()voidtestRestoreRemovesMixin()Test that after restore(), a subsequently added mixin type is removedvoidtestRestoreRootVersionFail()Test if restoring the root version fails.voidtestRestoreRootVersionFailJcr2()Test if restoring the root version fails.voidtestRestoreSetsBaseVersion()Test if restoring a node sets the jcr:baseVersion property correctly.voidtestRestoreSetsBaseVersionJcr2()Test if restoring a node sets the jcr:baseVersion property correctly.voidtestRestoreSetsBaseVersionJcr2_2()Test if restoring a node sets the jcr:baseVersion property correctly.voidtestRestoreSetsBaseVersionJcr2_3()Test if restoring a node sets the jcr:baseVersion property correctly.voidtestRestoreSetsBaseVersionJcr2_4()Test if restoring a node sets the jcr:baseVersion property correctly.voidtestRestoreSetsIsCheckedOutToFalse()Restoring a node set the jcr:isCheckedOut property to false.voidtestRestoreSetsIsCheckedOutToFalseJcr2()Restoring a node set the jcr:isCheckedOut property to false.voidtestRestoreSetsIsCheckedOutToFalseJcr2_2()Restoring a node set the jcr:isCheckedOut property to false.voidtestRestoreSetsIsCheckedOutToFalseJcr2_4()Restoring a node set the jcr:isCheckedOut property to false.voidtestRestoreSetsIsCheckedOutToFalseJcr3()Restoring a node set the jcr:isCheckedOut property to false.voidtestRestoreWithInvalidVersion()Test if restoring a node with an invalid Version throws a VersionExceptionvoidtestRestoreWithInvalidVersionJcr2()Test if restoring a node with an invalid Version throws a VersionExceptionvoidtestRestoreWithPendingChanges()Test if InvalidItemStateException is thrown if the node has pending changes.voidtestRestoreWithPendingChangesJcr2()Test if InvalidItemStateException is thrown if the node has pending changes.voidtestRestoreWithPendingChangesJcr2_2()Test if InvalidItemStateException is thrown if the node has pending changes.voidtestRestoreWithPendingChangesJcr2_3()Test if InvalidItemStateException is thrown if the node has pending changes.voidtestRestoreWithPendingChangesJcr2_4()Test if InvalidItemStateException is thrown if the node has pending changes.voidtestRestoreWithUUIDConflict()Tests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.voidtestRestoreWithUUIDConflictJcr2()Tests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.voidtestRestoreWithUUIDConflictJcr2_2()Tests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.voidtestRestoreWithUUIDConflictJcr2_3()Tests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.voidtestRestoreWithUUIDConflictJcr2_4()Tests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.-
Methods inherited from class org.apache.jackrabbit.test.api.version.AbstractVersionTest
createVersionableNode, getNumberOfVersions
-
Methods inherited from class org.apache.jackrabbit.test.AbstractJCRTest
checkSupportedOption, cleanUp, cleanUpTestRoot, createRandomString, ensureCanSetProperty, ensureCanSetProperty, ensureCanSetProperty, ensureKnowsNodeType, ensureLockingSupported, ensureMixinType, ensureMultipleWorkspacesSupported, getHelper, getJcrValue, getLocalName, getNonExistingWorkspaceName, getPrefix, getProperty, getProperty, getQualifiedName, getSize, isSupported, needsMixin, run
-
Methods inherited from class junit.framework.TestCase
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, countTestCases, createResult, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, runBare, runTest, setName, toString
-
-
-
-
Method Detail
-
setUp
protected void setUp() throws Exception- Overrides:
setUpin classAbstractVersionTest- Throws:
Exception
-
tearDown
protected void tearDown() throws Exception- Overrides:
tearDownin classAbstractVersionTest- Throws:
Exception
-
testRestoreRootVersionFail
public void testRestoreRootVersionFail() throws RepositoryExceptionTest if restoring the root version fails.- Throws:
RepositoryException
-
testRestoreRootVersionFailJcr2
public void testRestoreRootVersionFailJcr2() throws RepositoryExceptionTest if restoring the root version fails.- Throws:
RepositoryException
-
testRestoreOnCheckedInNode
public void testRestoreOnCheckedInNode() throws RepositoryExceptionTest if restoring a node works on checked-in node.- Throws:
RepositoryException
-
testRestoreOnCheckedInNodeJcr2_1
public void testRestoreOnCheckedInNodeJcr2_1() throws RepositoryExceptionTest if restoring a node works on checked-in node.- Throws:
RepositoryException
-
testRestoreOnCheckedInNodeJcr2_2
public void testRestoreOnCheckedInNodeJcr2_2() throws RepositoryExceptionTest if restoring a node works on checked-in node.- Throws:
RepositoryException
-
testRestoreOnCheckedInNodeJcr2_3
public void testRestoreOnCheckedInNodeJcr2_3() throws RepositoryExceptionTest if restoring a node works on checked-in node.- Throws:
RepositoryException
-
testRestoreOnCheckedInNodeJcr2_4
public void testRestoreOnCheckedInNodeJcr2_4() throws RepositoryExceptionTest if restoring a node works on checked-in node.- Throws:
RepositoryException
-
testRestoreOnCheckedOutNode
public void testRestoreOnCheckedOutNode() throws RepositoryExceptionTest if restoring a node works on checked-out node.- Throws:
RepositoryException
-
testRestoreOnCheckedOutNodeJcr2
public void testRestoreOnCheckedOutNodeJcr2() throws RepositoryExceptionTest if restoring a node works on checked-out node.- Throws:
RepositoryException
-
testRestoreOnCheckedOutNodeJcr2_2
public void testRestoreOnCheckedOutNodeJcr2_2() throws RepositoryExceptionTest if restoring a node works on checked-out node.- Throws:
RepositoryException
-
testRestoreOnCheckedOutNodeJcr2_3
public void testRestoreOnCheckedOutNodeJcr2_3() throws RepositoryExceptionTest if restoring a node works on checked-out node.- Throws:
RepositoryException
-
testRestoreOnCheckedOutNodeJcr2_4
public void testRestoreOnCheckedOutNodeJcr2_4() throws RepositoryExceptionTest if restoring a node works on checked-out node.- Throws:
RepositoryException
-
testRestoreSetsIsCheckedOutToFalse
public void testRestoreSetsIsCheckedOutToFalse() throws RepositoryExceptionRestoring a node set the jcr:isCheckedOut property to false.- Throws:
RepositoryException
-
testRestoreSetsIsCheckedOutToFalseJcr2
public void testRestoreSetsIsCheckedOutToFalseJcr2() throws RepositoryExceptionRestoring a node set the jcr:isCheckedOut property to false.- Throws:
RepositoryException
-
testRestoreSetsIsCheckedOutToFalseJcr2_2
public void testRestoreSetsIsCheckedOutToFalseJcr2_2() throws RepositoryExceptionRestoring a node set the jcr:isCheckedOut property to false.- Throws:
RepositoryException
-
testRestoreSetsIsCheckedOutToFalseJcr3
public void testRestoreSetsIsCheckedOutToFalseJcr3() throws RepositoryExceptionRestoring a node set the jcr:isCheckedOut property to false.- Throws:
RepositoryException
-
testRestoreSetsIsCheckedOutToFalseJcr2_4
public void testRestoreSetsIsCheckedOutToFalseJcr2_4() throws RepositoryExceptionRestoring a node set the jcr:isCheckedOut property to false.- Throws:
RepositoryException
-
testRestoreCorrectProperty
public void testRestoreCorrectProperty() throws RepositoryExceptionTest if restoring a node restores the correct property- Throws:
RepositoryException
-
testRestoreCorrectPropertyJcr2
public void testRestoreCorrectPropertyJcr2() throws RepositoryExceptionTest if restoring a node restores the correct property- Throws:
RepositoryException
-
testRestoreCorrectPropertyJcr2_2
public void testRestoreCorrectPropertyJcr2_2() throws RepositoryExceptionTest if restoring a node restores the correct property- Throws:
RepositoryException
-
testRestoreCorrectPropertyJcr2_3
public void testRestoreCorrectPropertyJcr2_3() throws RepositoryExceptionTest if restoring a node restores the correct property- Throws:
RepositoryException
-
testRestoreCorrectPropertyJcr2_4
public void testRestoreCorrectPropertyJcr2_4() throws RepositoryExceptionTest if restoring a node restores the correct property- Throws:
RepositoryException
-
testRestoreSetsBaseVersion
public void testRestoreSetsBaseVersion() throws RepositoryExceptionTest if restoring a node sets the jcr:baseVersion property correctly.- Throws:
RepositoryException
-
testRestoreSetsBaseVersionJcr2
public void testRestoreSetsBaseVersionJcr2() throws RepositoryExceptionTest if restoring a node sets the jcr:baseVersion property correctly.- Throws:
RepositoryException
-
testRestoreSetsBaseVersionJcr2_2
public void testRestoreSetsBaseVersionJcr2_2() throws RepositoryExceptionTest if restoring a node sets the jcr:baseVersion property correctly.- Throws:
RepositoryException
-
testRestoreSetsBaseVersionJcr2_3
public void testRestoreSetsBaseVersionJcr2_3() throws RepositoryExceptionTest if restoring a node sets the jcr:baseVersion property correctly.- Throws:
RepositoryException
-
testRestoreSetsBaseVersionJcr2_4
public void testRestoreSetsBaseVersionJcr2_4() throws RepositoryExceptionTest if restoring a node sets the jcr:baseVersion property correctly.- Throws:
RepositoryException
-
testRestoreWithPendingChanges
public void testRestoreWithPendingChanges() throws RepositoryExceptionTest if InvalidItemStateException is thrown if the node has pending changes.- Throws:
RepositoryException
-
testRestoreWithPendingChangesJcr2
public void testRestoreWithPendingChangesJcr2() throws RepositoryExceptionTest if InvalidItemStateException is thrown if the node has pending changes.- Throws:
RepositoryException
-
testRestoreWithPendingChangesJcr2_2
public void testRestoreWithPendingChangesJcr2_2() throws RepositoryExceptionTest if InvalidItemStateException is thrown if the node has pending changes.- Throws:
RepositoryException
-
testRestoreWithPendingChangesJcr2_3
public void testRestoreWithPendingChangesJcr2_3() throws RepositoryExceptionTest if InvalidItemStateException is thrown if the node has pending changes.- Throws:
RepositoryException
-
testRestoreWithPendingChangesJcr2_4
public void testRestoreWithPendingChangesJcr2_4() throws RepositoryExceptionTest if InvalidItemStateException is thrown if the node has pending changes.- Throws:
RepositoryException
-
testRestoreInvalidVersion
public void testRestoreInvalidVersion() throws RepositoryExceptionVersionException expected on Node.restore(Version, boolean) if the specified version is not part of this node's version history.- Throws:
RepositoryException
-
testRestoreInvalidVersionJcr2
public void testRestoreInvalidVersionJcr2() throws RepositoryExceptionVersionException expected on Node.restore(Version, boolean) if the specified version is not part of this node's version history.- Throws:
RepositoryException
-
testRestoreInvalidVersion2
public void testRestoreInvalidVersion2() throws RepositoryExceptionVersionException expected on Node.restore(String, boolean) if the specified version is not part of this node's version history.- Throws:
RepositoryException
-
testRestoreInvalidVersion2Jcr2
public void testRestoreInvalidVersion2Jcr2() throws RepositoryExceptionVersionException expected on Node.restore(String, boolean) if the specified version is not part of this node's version history.- Throws:
RepositoryException
-
testRestoreNonVersionableNode
public void testRestoreNonVersionableNode() throws RepositoryExceptionTest calling Node.restore(String, boolean) on a non-versionable node.- Throws:
RepositoryException- See Also:
Node.restore(String, boolean)
-
testRestoreNonVersionableNodeJcr2_2
public void testRestoreNonVersionableNodeJcr2_2() throws RepositoryExceptionTest restoring on a non-versionable node.- Throws:
RepositoryException- See Also:
Node.restore(String, boolean)
-
testRestoreNonVersionableNode2
public void testRestoreNonVersionableNode2() throws RepositoryExceptionTest calling Node.restore(Version, String, boolean) on a non-versionable node.- Throws:
RepositoryException- See Also:
Node.restore(Version, String, boolean)
-
testRestoreNonVersionableNode3
public void testRestoreNonVersionableNode3() throws RepositoryExceptionTest calling Node.restore(Version, boolean) on a non-versionable node.- Throws:
RepositoryException- See Also:
Node.restore(Version, boolean)
-
testRestoreNonVersionableNode3Jcr2_2
public void testRestoreNonVersionableNode3Jcr2_2() throws RepositoryExceptionTest restoring on a non-versionable node.- Throws:
RepositoryException- See Also:
Node.restore(Version, boolean)
-
testRestoreWithInvalidVersion
public void testRestoreWithInvalidVersion() throws RepositoryExceptionTest if restoring a node with an invalid Version throws a VersionException- Throws:
RepositoryException
-
testRestoreWithInvalidVersionJcr2
public void testRestoreWithInvalidVersionJcr2() throws RepositoryExceptionTest if restoring a node with an invalid Version throws a VersionException- Throws:
RepositoryException
-
testRestoreWithUUIDConflict
public void testRestoreWithUUIDConflict() throws RepositoryException, NotExecutableExceptionTests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.
-
testRestoreWithUUIDConflictJcr2
public void testRestoreWithUUIDConflictJcr2() throws RepositoryException, NotExecutableExceptionTests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.
-
testRestoreWithUUIDConflictJcr2_2
public void testRestoreWithUUIDConflictJcr2_2() throws RepositoryException, NotExecutableExceptionTests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.
-
testRestoreWithUUIDConflictJcr2_3
public void testRestoreWithUUIDConflictJcr2_3() throws RepositoryException, NotExecutableExceptionTests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.
-
testRestoreWithUUIDConflictJcr2_4
public void testRestoreWithUUIDConflictJcr2_4() throws RepositoryException, NotExecutableExceptionTests if restoring theVersionof an existing node throws anItemExistsExceptionif removeExisting is set to FALSE.
-
testRestoreChild1
public void testRestoreChild1() throws RepositoryException- Throws:
RepositoryException
-
testRestoreRemoved
public void testRestoreRemoved() throws RepositoryException- Throws:
RepositoryException
-
testRestoreRemovedJcr2
public void testRestoreRemovedJcr2() throws RepositoryException- Throws:
RepositoryException
-
testRestoreChild1Jcr2
public void testRestoreChild1Jcr2() throws RepositoryException- Throws:
RepositoryException
-
testRestoreChild1Jcr2_2
public void testRestoreChild1Jcr2_2() throws RepositoryException- Throws:
RepositoryException
-
testRestoreChild1Jcr2_3
public void testRestoreChild1Jcr2_3() throws RepositoryException- Throws:
RepositoryException
-
testRestoreChild1Jcr2_4
public void testRestoreChild1Jcr2_4() throws RepositoryException- Throws:
RepositoryException
-
testRestoreLabel
public void testRestoreLabel() throws RepositoryExceptionTest the restore of a versionable node using a label.- Throws:
RepositoryException
-
testRestoreLabelJcr2
public void testRestoreLabelJcr2() throws RepositoryExceptionTest the restore of a versionable node using a label.- Throws:
RepositoryException
-
testRestoreName
public void testRestoreName() throws RepositoryException, NotExecutableExceptionTest the restore of the OPV=Version child nodes.
-
testRestoreNameJcr2
public void testRestoreNameJcr2() throws RepositoryException, NotExecutableExceptionTest the restore of the OPV=Version child nodes.
-
testRestoreOrder
public void testRestoreOrder() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrderJcr2
public void testRestoreOrderJcr2() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrderJcr2_2
public void testRestoreOrderJcr2_2() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrderJcr2_3
public void testRestoreOrderJcr2_3() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrderJcr2_4
public void testRestoreOrderJcr2_4() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrder2
public void testRestoreOrder2() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrder2Jcr2
public void testRestoreOrder2Jcr2() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrder2Jcr2_2
public void testRestoreOrder2Jcr2_2() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrder2Jcr2_3
public void testRestoreOrder2Jcr2_3() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreOrder2Jcr2_4
public void testRestoreOrder2Jcr2_4() throws RepositoryException, NotExecutableExceptionTest the child ordering of restored nodes.
-
testRestoreRemovesMixin
public void testRestoreRemovesMixin() throws RepositoryException, NotExecutableExceptionTest that after restore(), a subsequently added mixin type is removed
-
-