mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
Try LC_ALL instead.
This commit is contained in:
parent
77fc8a9d33
commit
6a1e9e80b2
1 changed files with 3 additions and 3 deletions
|
@ -490,14 +490,14 @@ class CakeNumberTest extends CakeTestCase {
|
|||
* @return void
|
||||
*/
|
||||
public function testReadableSizeLocalized() {
|
||||
$restore = setlocale(LC_NUMERIC, 0);
|
||||
setlocale(LC_NUMERIC, 'de_DE');
|
||||
$restore = setlocale(LC_ALL, 0);
|
||||
setlocale(LC_ALL, 'de_DE');
|
||||
$result = $this->Number->toReadableSize(1321205);
|
||||
$this->assertEquals('1,26 MB', $result);
|
||||
|
||||
$result = $this->Number->toReadableSize(1024 * 1024 * 1024 * 512);
|
||||
$this->assertEquals('512,00 GB', $result);
|
||||
setlocale(LC_NUMERIC, $restore);
|
||||
setlocale(LC_ALL, $restore);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Reference in a new issue