示例#1
0
 /**
  * @expectedException RuntimeException
  */
 public function testWrongCredentialsInUrl()
 {
     $console = $this->getMock('Composer\\IO\\IOInterface');
     $console->expects($this->once())->method('isInteractive')->will($this->returnValue(true));
     $output = "svn: OPTIONS of 'http://corp.svn.local/repo':";
     $output .= " authorization failed: Could not authenticate to server:";
     $output .= " rejected Basic challenge (http://corp.svn.local/)";
     $process = $this->getMock('Composer\\Util\\ProcessExecutor');
     $process->expects($this->once())->method('execute')->will($this->returnValue(1));
     $process->expects($this->once())->method('getErrorOutput')->will($this->returnValue($output));
     $svn = new SvnDriver('http://*****:*****@corp.svn.local/repo', $console, $process);
     $svn->getTags();
 }