コード例 #1
0
    public function testGetWorkingCopyUrlOnOldFormatWorkingCopyAndUpgradeRejected()
    {
        $this->_io->writeln(array('', '<error>error message</error>', ''))->shouldBeCalled();
        $this->_io->askConfirmation('Run "svn upgrade"', false)->willReturn(false)->shouldBeCalled();
        $this->_expectCommand("svn --non-interactive info --xml '/path/to/working-copy'", '', 'error message', RepositoryCommandException::SVN_ERR_WC_UPGRADE_REQUIRED);
        $exception_msg = <<<MESSAGE
Command:
svn --non-interactive info --xml '/path/to/working-copy'
Error #%d:
error message
MESSAGE;
        $this->setExpectedException('ConsoleHelpers\\SVNBuddy\\Exception\\RepositoryCommandException', sprintf($exception_msg, RepositoryCommandException::SVN_ERR_WC_UPGRADE_REQUIRED));
        $this->_repositoryConnector->getWorkingCopyUrl('/path/to/working-copy');
    }
コード例 #2
0
ファイル: AbstractCommand.php プロジェクト: aik099/svn-buddy
 /**
  * Returns URL to the working copy.
  *
  * @return string
  */
 protected function getWorkingCopyUrl()
 {
     return $this->repositoryConnector->getWorkingCopyUrl($this->getWorkingCopyPath());
 }