From: Xinchen Hui Date: Sat, 21 Feb 2015 04:36:38 +0000 (+0800) Subject: Fixed test fails for bug68557 X-Git-Tag: PRE_PHP7_EREG_MYSQL_REMOVALS~92 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ea94be490a5e620a86883963fa5dfa421a2477dc;p=php Fixed test fails for bug68557 --- diff --git a/ext/spl/tests/bug68557-win32.phpt b/ext/spl/tests/bug68557-win32.phpt deleted file mode 100644 index 95502a53e8..0000000000 --- a/ext/spl/tests/bug68557-win32.phpt +++ /dev/null @@ -1,44 +0,0 @@ ---TEST-- -Bug #68557 (SplFileInfo::getPathname() may be broken) ---SKIPIF-- - ---FILE-- -seek(0); -var_dump($d->current()->getPathname()); - -$d->seek(1); -var_dump($d->current()->getPathname()); - -$d->seek(0); -var_dump($d->current()->getPathname()); - -$d->seek(1); -var_dump($d->current()->getPathname()); - -$d->seek(2); -var_dump($d->current()->getPathname()); -?> ---CLEAN-- - ---EXPECTF-- -string(%d) "%s\tmp\." -string(%d) "%s\tmp\.." -string(%d) "%s\tmp\." -string(%d) "%s\tmp\.." -string(%d) "%s\tmp\a" - diff --git a/ext/spl/tests/bug68557.phpt b/ext/spl/tests/bug68557.phpt index c862bda7cf..c1ac95257b 100644 --- a/ext/spl/tests/bug68557.phpt +++ b/ext/spl/tests/bug68557.phpt @@ -1,11 +1,5 @@ --TEST-- Bug #68557 (SplFileInfo::getPathname() may be broken) ---SKIPIF-- - --FILE-- seek(0); -var_dump($d->current()->getPathname()); +$path0 = $d->current()->getPathname(); $d->seek(1); -var_dump($d->current()->getPathname()); +$path1 = $d->current()->getPathname(); + +$d->seek(2); +$path2 = $d->current()->getPathname(); $d->seek(0); -var_dump($d->current()->getPathname()); +var_dump($path0 === $d->current()->getPathname()); $d->seek(1); -var_dump($d->current()->getPathname()); +var_dump($path1 === $d->current()->getPathname()); $d->seek(2); -var_dump($d->current()->getPathname()); +var_dump($path2 === $d->current()->getPathname()); + +$d->seek(0); +var_dump($path0 === $d->current()->getPathname()); ?> --CLEAN-- --EXPECTF-- -string(%d) "%s/tmp/b" -string(%d) "%s/tmp/a" -string(%d) "%s/tmp/b" -string(%d) "%s/tmp/a" -string(%d) "%s/tmp/.." - +bool(true) +bool(true) +bool(true) +bool(true)