diff options
author | Etienne Kneuss <colder@php.net> | 2008-05-16 13:22:02 +0000 |
---|---|---|
committer | Etienne Kneuss <colder@php.net> | 2008-05-16 13:22:02 +0000 |
commit | 1d2bfff3a95c99651ede415d635f69116e835bb6 (patch) | |
tree | 9317f6b7de55c7dcab93da3b9e5987831e80f2cd /ext/spl/tests/dit_004.phpt | |
parent | f4458df3d45357359d1a2cf29e6e3ad0b5012fe1 (diff) | |
download | php-git-1d2bfff3a95c99651ede415d635f69116e835bb6.tar.gz |
Fix FilesystemIterator with ./..
Diffstat (limited to 'ext/spl/tests/dit_004.phpt')
-rw-r--r-- | ext/spl/tests/dit_004.phpt | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/ext/spl/tests/dit_004.phpt b/ext/spl/tests/dit_004.phpt new file mode 100644 index 0000000000..704487f155 --- /dev/null +++ b/ext/spl/tests/dit_004.phpt @@ -0,0 +1,26 @@ +--TEST-- +SPL: DirectoryIterator and clone +--SKIPIF-- +<?php if (!extension_loaded("spl")) print "skip"; ?> +--FILE-- +<?php +$a = new DirectoryIterator(__DIR__); +$b = clone $a; +var_dump((string)$b == (string)$a); +var_dump($a->key(), $b->key()); +$a->next(); +$a->next(); +$a->next(); +$c = clone $a; +var_dump((string)$c == (string)$a); +var_dump($a->key(), $c->key()); +?> +===DONE=== +--EXPECTF-- +bool(true) +int(0) +int(0) +bool(true) +int(3) +int(3) +===DONE=== |