summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohannes Schlüter <johannes@php.net>2008-10-19 18:07:04 +0000
committerJohannes Schlüter <johannes@php.net>2008-10-19 18:07:04 +0000
commit0e306ec3bc63e914367f7fa730dede03165df7dc (patch)
tree0deaca0cc76f4980cf846fa6812906162a4fb09a
parentc31e0c803ecf6950c3d0070f3d7df9f9c9501f5f (diff)
downloadphp-git-0e306ec3bc63e914367f7fa730dede03165df7dc.tar.gz
Add %S and %A to EXPECTF, they work like %s and %a but match empty strings, too
-rwxr-xr-xrun-tests.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/run-tests.php b/run-tests.php
index 9926735de6..7ca17d23b4 100755
--- a/run-tests.php
+++ b/run-tests.php
@@ -1551,7 +1551,9 @@ COMMAND $cmd
// Stick to basics
$wanted_re = str_replace('%e', '\\' . DIRECTORY_SEPARATOR, $wanted_re);
$wanted_re = str_replace('%s', '[^\r\n]+', $wanted_re);
+ $wanted_re = str_replace('%S', '[^\r\n]*', $wanted_re);
$wanted_re = str_replace('%a', '.+', $wanted_re);
+ $wanted_re = str_replace('%A', '.*', $wanted_re);
$wanted_re = str_replace('%w', '\s*', $wanted_re);
$wanted_re = str_replace('%i', '[+-]?\d+', $wanted_re);
$wanted_re = str_replace('%d', '\d+', $wanted_re);