1
0
Fork 0

Fix tests on windows, fixes #3141

pull/2085/merge
Jordi Boggiano 2014-09-30 15:17:53 +01:00
parent 1c051d9c8e
commit 472c8a5113
1 changed files with 1 additions and 1 deletions

View File

@ -115,7 +115,7 @@ class ConfigTest extends \PHPUnit_Framework_TestCase
$config->merge(array('config' => array('a' => 'b', 'c' => '{$a}'))); $config->merge(array('config' => array('a' => 'b', 'c' => '{$a}')));
$config->merge(array('config' => array('bin-dir' => '$HOME', 'cache-dir' => '~/foo/'))); $config->merge(array('config' => array('bin-dir' => '$HOME', 'cache-dir' => '~/foo/')));
$home = rtrim(getenv('HOME'), '\\/'); $home = rtrim(getenv('HOME') ?: getenv('USERPROFILE'), '\\/');
$this->assertEquals('b', $config->get('c')); $this->assertEquals('b', $config->get('c'));
$this->assertEquals($home.'/', $config->get('bin-dir')); $this->assertEquals($home.'/', $config->get('bin-dir'));
$this->assertEquals($home.'/foo', $config->get('cache-dir')); $this->assertEquals($home.'/foo', $config->get('cache-dir'));