Skip to content

Commit

Permalink
tests: skip if not PHP 8.1 krakjoe#172
Browse files Browse the repository at this point in the history
  • Loading branch information
kornrunner committed Jul 13, 2023
1 parent 6c07b8a commit 510989a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
8 changes: 5 additions & 3 deletions tests/bugs/gh172.phpt
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
--TEST--
handle ZEND_VERIFY_NEVER_TYPE when uopz.exit disabled
--EXTENSIONS--
uopz
--SKIPIF--
<?php
uopz_allow_exit(true);
if (version_compare(PHP_VERSION, '8.1.0', '<')) {
die("skip: PHP 8.1+ only");
die("skip PHP 8.1+ only");
}
--EXTENSIONS--
uopz
--INI--
uopz.disable=0
uopz.exit=0
Expand All @@ -15,6 +16,7 @@ xdebug.enable=0
--FILE--
<?php

uopz_allow_exit(false);
function x(): never {
exit(10);
}
Expand Down
7 changes: 4 additions & 3 deletions tests/bugs/gh172a.phpt
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
--TEST--
do not handle ZEND_VERIFY_NEVER_TYPE if not uopz_allow_exit
--EXTENSIONS--
uopz
--SKIPIF--
<?php
uopz_allow_exit(true);
if (version_compare(PHP_VERSION, '8.1.0', '<')) {
die("skip: PHP 8.1+ only");
die("skip PHP 8.1+ only");
}
--EXTENSIONS--
uopz
--INI--
uopz.disable=0
uopz.exit=1
Expand Down

0 comments on commit 510989a

Please sign in to comment.