diff options
| author | Derick Rethans <derick@php.net> | 2002-10-18 20:34:41 +0000 |
|---|---|---|
| committer | Derick Rethans <derick@php.net> | 2002-10-18 20:34:41 +0000 |
| commit | ca1e7301ab80093de57726115b44dc7b02159061 (patch) | |
| tree | 7096be36d3dc133084e3d9b6134494e69c64a3cb | |
| parent | 7de1f45aaa1a3866ca8ee072d6bf90fcf2a35720 (diff) | |
| download | php-git-ca1e7301ab80093de57726115b44dc7b02159061.tar.gz | |
- Added %x for HEX chars
- Added %d as alias for %i (too much C here :)
- Added beginning and end markers to regexp
| -rwxr-xr-x | run-tests.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/run-tests.php b/run-tests.php index 7821f490bd..c668b2a8b7 100755 --- a/run-tests.php +++ b/run-tests.php @@ -528,13 +528,15 @@ COMMAND $cmd // Stick to basics $wanted_re = str_replace("%s", ".+?", $wanted_re); //not greedy $wanted_re = str_replace("%i", "[0-9]+", $wanted_re); + $wanted_re = str_replace("%d", "[0-9]+", $wanted_re); + $wanted_re = str_replace("%x", "[0-9a-fA-F]+", $wanted_re); $wanted_re = str_replace("%f", "[0-9\.+\-]+", $wanted_re); /* DEBUG YOUR REGEX HERE var_dump($wanted); print(str_repeat('=', 80) . "\n"); var_dump($output); */ - if (preg_match("/$wanted_re/s", $output)) { + if (preg_match("/^$wanted_re$/s", $output)) { echo "PASS $tested\n"; return 'PASSED'; } |
