From 464cff0477416009343a1758433778c5d7d0e51d Mon Sep 17 00:00:00 2001 From: Stefan Siegl Date: Thu, 22 May 2014 23:58:44 +0200 Subject: [PATCH] test unwind behaviour on PHP notices & warnings, refs #94 --- tests/fatal_error_ignore_non_fatals.phpt | 31 ++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 tests/fatal_error_ignore_non_fatals.phpt diff --git a/tests/fatal_error_ignore_non_fatals.phpt b/tests/fatal_error_ignore_non_fatals.phpt new file mode 100644 index 0000000..14a47bf --- /dev/null +++ b/tests/fatal_error_ignore_non_fatals.phpt @@ -0,0 +1,31 @@ +--TEST-- +Test V8::executeString() : Fatal Error handler to ignore warnings +--SKIPIF-- + +--FILE-- +foo = function() { + echo $bar; + trigger_error('Foo Bar!', E_USER_WARNING); + echo "blar foo\n"; +}; + +$script = <<executeString($script); + +?> +===EOF=== +--EXPECTF-- +Notice: Undefined variable: bar in %s/fatal_error_ignore_non_fatals.php on line 6 + +Warning: Foo Bar! in %s/fatal_error_ignore_non_fatals.php on line 7 +blar foo +===EOF=== \ No newline at end of file