Skip to content

Commit

Permalink
Split test in < and >= PHP 7 versions
Browse files Browse the repository at this point in the history
  • Loading branch information
derickr committed Sep 12, 2015
1 parent eb02df4 commit 5aa6867
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
30 changes: 30 additions & 0 deletions tests/bug00422-php70.phpt
@@ -0,0 +1,30 @@
--TEST--
Test for bug #422: Segfaults when using code coverage with a parse error in the script
--SKIPIF--
<?php if (!version_compare(phpversion(), "7.0", '>=')) echo "skip >= PHP 7.0 needed\n"; ?>
--INI--
xdebug.default_enable=1
xdebug.auto_trace=0
xdebug.trace_options=0
xdebug.trace_output_dir=/tmp
xdebug.collect_params=1
xdebug.collect_return=0
xdebug.auto_profile=0
xdebug.profiler_enable=0
xdebug.dump_globals=0
xdebug.show_mem_delta=0
xdebug.trace_format=0
xdebug.extended_info=1
--FILE--
<?php
function hdl(){}
set_error_handler('hdl');
xdebug_start_code_coverage(XDEBUG_CC_UNUSED | XDEBUG_CC_DEAD_CODE);
try {
require_once 'bug00422.inc';
} catch (ParseError $err) {
}
echo "END";
?>
--EXPECT--
END
2 changes: 2 additions & 0 deletions tests/bug00422.phpt
@@ -1,5 +1,7 @@
--TEST--
Test for bug #422: Segfaults when using code coverage with a parse error in the script
--SKIPIF--
<?php if (!version_compare(phpversion(), "7.0", '<')) echo "skip < PHP 7.0 needed\n"; ?>
--INI--
xdebug.default_enable=1
xdebug.auto_trace=0
Expand Down

0 comments on commit 5aa6867

Please sign in to comment.