summaryrefslogtreecommitdiff
path: root/_test/tests/inc/auth_loadacl.test.php
diff options
context:
space:
mode:
authorChristopher Smith <chris@jalakai.co.uk>2013-10-25 15:15:58 +0100
committerChristopher Smith <chris@jalakai.co.uk>2013-10-25 15:15:58 +0100
commit30eae85545994c10dcacb2d7becceaf569c99f65 (patch)
treec3a2bb1b73f05bff39f86497d2967dc832eaa4d5 /_test/tests/inc/auth_loadacl.test.php
parent0113757259202e06f0316ef4be0f938b134e6e9c (diff)
downloadrpg-30eae85545994c10dcacb2d7becceaf569c99f65.tar.gz
rpg-30eae85545994c10dcacb2d7becceaf569c99f65.tar.bz2
ensure locale is set back to the original value
Diffstat (limited to '_test/tests/inc/auth_loadacl.test.php')
-rw-r--r--_test/tests/inc/auth_loadacl.test.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/_test/tests/inc/auth_loadacl.test.php b/_test/tests/inc/auth_loadacl.test.php
index 64ab1b9cf..e8d9f6696 100644
--- a/_test/tests/inc/auth_loadacl.test.php
+++ b/_test/tests/inc/auth_loadacl.test.php
@@ -97,11 +97,13 @@ ACL;
function test_FS2867() {
global $USERINFO;
+ $old_locale = setlocale(LC_ALL, '0');
setlocale(LC_ALL, "English_United States.1252"); // should only succeed on windows systems
setlocale(LC_ALL, "en_US.UTF-8"); // should succeed on other systems
// no point continuing with this test if \s doesn't match A0
if (!preg_match('/\s/',"\xa0")) {
+ setlocale(LC_ALL, $old_locale);
$this->markTestSkipped('Unable to change locale.');
}
@@ -121,6 +123,7 @@ ACL;
"devangariठttha\t@ALL 2",
);
$this->assertEquals($expect, $this->auth_loadACL_testwrapper($acls));
+ setlocale(LC_ALL, $old_locale);
}
}