1
0
Fork 0

Attempt to fix travis build

pull/2118/merge
Jordi Boggiano 2013-07-26 15:44:24 +02:00
parent 1d91e43587
commit 7252078508
2 changed files with 11 additions and 13 deletions

View File

@ -14,6 +14,7 @@ namespace Composer\Test\Downloader;
use Composer\Downloader\GitDownloader;
use Composer\Config;
use Composer\Util\Filesystem;
class GitDownloaderTest extends \PHPUnit_Framework_TestCase
{
@ -221,10 +222,9 @@ class GitDownloaderTest extends \PHPUnit_Framework_TestCase
{
$expectedGitUpdateCommand = $this->winCompat("git remote set-url composer 'git://github.com/composer/composer' && git fetch composer && git fetch --tags composer");
$tmpDir = sys_get_temp_dir().DIRECTORY_SEPARATOR.'test-git-update';
if (!is_dir($tmpDir.'/.git')) {
mkdir($tmpDir.'/.git', true, 0777);
}
$tmpDir = realpath(sys_get_temp_dir()).DIRECTORY_SEPARATOR.'cmptest-'.md5(uniqid('', true));
$fs = new Filesystem;
$fs->ensureDirectoryExists($tmpDir.'/.git');
$packageMock = $this->getMock('Composer\Package\PackageInterface');
$packageMock->expects($this->any())
->method('getSourceReference')
@ -268,10 +268,9 @@ class GitDownloaderTest extends \PHPUnit_Framework_TestCase
{
$expectedGitUpdateCommand = $this->winCompat("git remote set-url composer 'git://github.com/composer/composer' && git fetch composer && git fetch --tags composer");
$tmpDir = sys_get_temp_dir().DIRECTORY_SEPARATOR.'test-git-update';
if (!is_dir($tmpDir.'/.git')) {
mkdir($tmpDir.'/.git', true, 0777);
}
$tmpDir = realpath(sys_get_temp_dir()).DIRECTORY_SEPARATOR.'cmptest-'.md5(uniqid('', true));
$fs = new Filesystem;
$fs->ensureDirectoryExists($tmpDir.'/.git');
$packageMock = $this->getMock('Composer\Package\PackageInterface');
$packageMock->expects($this->any())
->method('getSourceReference')

View File

@ -13,6 +13,7 @@
namespace Composer\Test\Downloader;
use Composer\Downloader\HgDownloader;
use Composer\Util\Filesystem;
class HgDownloaderTest extends \PHPUnit_Framework_TestCase
{
@ -84,11 +85,9 @@ class HgDownloaderTest extends \PHPUnit_Framework_TestCase
public function testUpdate()
{
$tmpDir = sys_get_temp_dir().'/test-hg-update';
if (!is_dir($tmpDir.'/.hg')) {
mkdir($tmpDir.'/.hg', true, 0777);
}
$tmpDir = realpath(sys_get_temp_dir()).DIRECTORY_SEPARATOR.'cmptest-'.md5(uniqid('', true));
$fs = new Filesystem;
$fs->ensureDirectoryExists($tmpDir.'/.hg');
$packageMock = $this->getMock('Composer\Package\PackageInterface');
$packageMock->expects($this->any())
->method('getSourceReference')