diff options
author | Anatol Belski <ab@php.net> | 2018-12-29 16:22:31 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2018-12-29 16:22:31 +0100 |
commit | 222fa032d272fb12e390b975d0a544c0e5b5f0da (patch) | |
tree | 84b06d725b7ef7e9038caf15a196f4ea1610f0db /Zend | |
parent | a2cb8228fe57cb8d3db0395fad96d01b1d0cb8bc (diff) | |
download | php-git-222fa032d272fb12e390b975d0a544c0e5b5f0da.tar.gz |
Add memory check to the test
Diffstat (limited to 'Zend')
-rw-r--r-- | Zend/tests/bug55509.phpt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Zend/tests/bug55509.phpt b/Zend/tests/bug55509.phpt index 4fc3299620..efcf918775 100644 --- a/Zend/tests/bug55509.phpt +++ b/Zend/tests/bug55509.phpt @@ -45,6 +45,13 @@ elseif (PHP_OS == 'FreeBSD') { if ($freeMemory < 2100*1024*1024) { die('skip Not enough memory.'); } +} elseif (PHP_OS == "WINNT") { + $s = trim(shell_exec("wmic OS get FreeVirtualMemory /Value 2>nil")); + $freeMemory = explode('=', $s)[1]*1; + + if ($freeMemory < 2.1*1024*1024) { + die('skip Not enough memory.'); + } } ?> --INI-- |