php/pftt2

--EXPECTF-- section comparison is broken

Opened this issue · 1 comments

cmb69 commented

Consider the following PHPT:

--TEST--
oops
--FILE--
<?php
echo "foo";
?>
--EXPECTF--
bar

This is certainly supposed to fail (outputs foo but expects bar), but with current HEAD it passes for me. I did some improvements to make the internally generated regex more strict (replaced the .* at the beginning and end with ^ and $, respectively), but the test still passed. I've quickly rewritten the relevant parts using java.util.regex instead of our port of org.apache.regexp and then the test failed.

cmb69 commented

FTR: php-test-pack-7.3.11 has 16224 tests; 7257 use EXPECTF and 75 use EXPECTREGEX.