Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed tests

  • Loading branch information...
commit 00361e00875e12e4ab38a4b5d37c44c1c3034e7c 1 parent d1a452b
@bboer authored
View
2  src/Composer/Repository/Vcs/GitHubDriver.php
@@ -270,7 +270,7 @@ protected function fetchRootIdentifier()
// cannot ask for authentication credentials (because we
// are not interactive) then we fallback to GitDriver.
$this->gitDriver = new GitDriver(
- $this->generateSshUrl(),
+ array('url' => $this->generateSshUrl()),
$this->io,
$this->config,
$this->process,
View
24 tests/Composer/Test/Repository/Vcs/GitHubDriverTest.php
@@ -77,7 +77,11 @@ public function testPrivateRepository()
->with($this->equalTo('github.com'), $this->equalTo($repoApiUrl), $this->equalTo(false))
->will($this->returnValue('{"master_branch": "test_master"}'));
- $gitHubDriver = new GitHubDriver($repoUrl, $io, $this->config, $process, $remoteFilesystem);
+ $repoConfig = array(
+ 'url' => $repoUrl,
+ );
+
+ $gitHubDriver = new GitHubDriver($repoConfig, $io, $this->config, $process, $remoteFilesystem);
$gitHubDriver->initialize();
$this->setAttribute($gitHubDriver, 'tags', array($identifier => $sha));
@@ -125,7 +129,11 @@ public function testPublicRepository()
->with($this->equalTo('github.com'), $this->equalTo($repoApiUrl), $this->equalTo(false))
->will($this->returnValue('{"master_branch": "test_master"}'));
- $gitHubDriver = new GitHubDriver($repoUrl, $io, $this->config, null, $remoteFilesystem);
+ $repoConfig = array(
+ 'url' => $repoUrl,
+ );
+
+ $gitHubDriver = new GitHubDriver($repoConfig, $io, $this->config, null, $remoteFilesystem);
$gitHubDriver->initialize();
$this->setAttribute($gitHubDriver, 'tags', array($identifier => $sha));
@@ -183,7 +191,11 @@ public function testPublicRepository2()
->with($this->equalTo('github.com'), $this->equalTo('https://api.github.com/repos/composer/packagist/commits/feature%2F3.2-foo'), $this->equalTo(false))
->will($this->returnValue('{"commit": {"committer":{ "date": "2012-09-10"}}}'));
- $gitHubDriver = new GitHubDriver($repoUrl, $io, $this->config, null, $remoteFilesystem);
+ $repoConfig = array(
+ 'url' => $repoUrl,
+ );
+
+ $gitHubDriver = new GitHubDriver($repoConfig, $io, $this->config, null, $remoteFilesystem);
$gitHubDriver->initialize();
$this->setAttribute($gitHubDriver, 'tags', array($identifier => $sha));
@@ -271,7 +283,11 @@ public function testPrivateRepositoryNoInteraction()
->method('splitLines')
->will($this->returnValue(array('* test_master')));
- $gitHubDriver = new GitHubDriver($repoUrl, $io, $this->config, $process, $remoteFilesystem);
+ $repoConfig = array(
+ 'url' => $repoUrl,
+ );
+
+ $gitHubDriver = new GitHubDriver($repoConfig, $io, $this->config, $process, $remoteFilesystem);
$gitHubDriver->initialize();
$this->assertEquals('test_master', $gitHubDriver->getRootIdentifier());
View
6 tests/Composer/Test/Repository/Vcs/SvnDriverTest.php
@@ -45,7 +45,11 @@ public function testWrongCredentialsInUrl()
'home' => sys_get_temp_dir() . '/composer-test',
),
));
- $svn = new SvnDriver('http://till:secret@corp.svn.local/repo', $console, $config, $process);
+ $repoConfig = array(
+ 'url' => 'http://till:secret@corp.svn.local/repo',
+ );
+
+ $svn = new SvnDriver($repoConfig, $console, $config, $process);
$svn->initialize();
}

0 comments on commit 00361e0

Please sign in to comment.
Something went wrong with that request. Please try again.