com php-src: Add a test for hard_timeout(bug #740 93): Zend/tests/bug74093.phpt
| From: | Xinchen Hui | Date: | Wed, 15 Feb 2017 05:51:45 +0000 |
| Subject: | com php-src: Add a test for hard_timeout(bug #740 93): Zend/tests/bug74093.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-97108@lists.php.net to get a copy of this message | ||
Commit: 6767ef05a54ca1afbc7d5fa679250d68ce90fa71
Author: Xinchen Hui <laruence@gmail.com> Wed, 15 Feb 2017 13:51:45 +0800
Parents: 1242f53ddb018cdba93a9ffe4f56554a6471901f
Branches: PHP-7.1 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=6767ef05a54ca1afbc7d5fa679250d68ce90fa71
Log:
Add a test for hard_timeout(bug #74093)
Bugs:
https://bugs.php.net/74093
Changed paths:
A Zend/tests/bug74093.phpt
Diff:
diff --git a/Zend/tests/bug74093..phpt b/Zend/tests/bug74093.phpt
new file mode 100644
index 0000000..91b4981
--- /dev/null
+++ b/Zend/tests/bug74093.phpt
@@ -0,0 +1,18 @@
+--TEST--
+Bug #74093 (Maximum execution time of n+2 seconds exceed not written in error_log)
+--SKIPIF--
+<?php
+if (getenv("SKIP_SLOW_TESTS")) die("skip slow test");
+?>
+--INI--
+memory_limit=1G
+max_execution_time=1
+hard_timeout=1
+--FILE--
+<?php
+$a1 = range(1, 100000);
+$a2 = range(100000, 999999);
+array_intersect($a1, $a2);
+?>
+--EXPECTF--
+Fatal error: Maximum execution time of 1+1 seconds exceeded (terminated) in %sbug74093.php on line
%d