mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
Merge branch '4.0' into 4
This commit is contained in:
commit
62057befdb
@ -77,7 +77,7 @@ class TempFolder
|
|||||||
// failing the above, try finding a namespaced silverstripe-cache dir in the system temp
|
// failing the above, try finding a namespaced silverstripe-cache dir in the system temp
|
||||||
$tempPath = Path::join(
|
$tempPath = Path::join(
|
||||||
sys_get_temp_dir(),
|
sys_get_temp_dir(),
|
||||||
'silverstripe-cache-php' . preg_replace('/[^\w-\.+]+/', '-', PHP_VERSION) .
|
'silverstripe-cache-php' . preg_replace('/[^\w\-\.+]+/', '-', PHP_VERSION) .
|
||||||
str_replace(array(' ', '/', ':', '\\'), '-', $base)
|
str_replace(array(' ', '/', ':', '\\'), '-', $base)
|
||||||
);
|
);
|
||||||
if (!@file_exists($tempPath)) {
|
if (!@file_exists($tempPath)) {
|
||||||
|
@ -29,7 +29,7 @@ class CoreTest extends SapphireTest
|
|||||||
$this->assertEquals(TempFolder::getTempFolder(BASE_PATH), $this->tempPath . DIRECTORY_SEPARATOR . $user);
|
$this->assertEquals(TempFolder::getTempFolder(BASE_PATH), $this->tempPath . DIRECTORY_SEPARATOR . $user);
|
||||||
} else {
|
} else {
|
||||||
$user = TempFolder::getTempFolderUsername();
|
$user = TempFolder::getTempFolderUsername();
|
||||||
$base = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'silverstripe-cache-php' . preg_replace('/[^\w-\.+]+/', '-', PHP_VERSION);
|
$base = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'silverstripe-cache-php' . preg_replace('/[^\w\-\.+]+/', '-', PHP_VERSION);
|
||||||
|
|
||||||
// A typical Windows location for where sites are stored on IIS
|
// A typical Windows location for where sites are stored on IIS
|
||||||
$this->assertEquals(
|
$this->assertEquals(
|
||||||
@ -55,7 +55,7 @@ class CoreTest extends SapphireTest
|
|||||||
{
|
{
|
||||||
parent::tearDown();
|
parent::tearDown();
|
||||||
$user = TempFolder::getTempFolderUsername();
|
$user = TempFolder::getTempFolderUsername();
|
||||||
$base = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'silverstripe-cache-php' . preg_replace('/[^\w-\.+]+/', '-', PHP_VERSION);
|
$base = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'silverstripe-cache-php' . preg_replace('/[^\w\-\.+]+/', '-', PHP_VERSION);
|
||||||
foreach (array(
|
foreach (array(
|
||||||
'C--inetpub-wwwroot-silverstripe-test-project',
|
'C--inetpub-wwwroot-silverstripe-test-project',
|
||||||
'-Users-joebloggs-Sites-silverstripe-test-project',
|
'-Users-joebloggs-Sites-silverstripe-test-project',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user