/**
  * Check $version->remove() is not possible. This must go through VersionHistory::remove.
  *
  * @expectedException \PHPCR\RepositoryException
  */
 public function testNodeRemoveOnVersion()
 {
     $version = $this->vm->checkpoint('/tests_version_base/simpleVersioned');
     $version->remove();
 }
 /**
  * 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');
 }