public function testGetLinearPredecessorNull() { $rootVersion = $this->vm->getVersionHistory('/tests_version_base/simpleVersioned')->getRootVersion(); // base version is at end of chain $this->assertNull($rootVersion->getLinearPredecessor()); }
/** * Try removing an unexisting version. * * @expectedException \PHPCR\Version\VersionException */ public function testDeleteUnexistingVersion() { $this->vm->checkpoint('/tests_version_base/versioned'); $history = $this->vm->getVersionHistory('/tests_version_base/versioned'); $history->removeVersion('unexisting'); }
/** * @expectedException \PHPCR\Version\VersionException */ public function testRestoreRootVersion() { $rootVersion = $this->vm->getVersionHistory('/tests_version_base/versioned')->getRootVersion(); $this->vm->restore(true, $rootVersion); }
/** * Try to remove unset label from a version. * @expectedException \PHPCR\Version\VersionException */ public function testRemoveUnsetLabel() { $history = $this->vm->getVersionHistory('/tests_version_base/versioned'); $history->removeVersionLabel('unsetLabel'); }