Annotation of embedaddon/php/ext/spl/tests/SplFileObject_fgetcsv_escape_error.phpt, revision 1.1.1.2
1.1 misho 1: --TEST--
1.1.1.2 ! misho 2: SplFileObject::fgetcsv with alternative delimiter
1.1 misho 3: --FILE--
4: <?php
5: $fp = fopen('SplFileObject__fgetcsv.csv', 'w+');
6: fwrite($fp, '"aaa","b""bb","ccc"');
7: fclose($fp);
8:
9: $fo = new SplFileObject('SplFileObject__fgetcsv.csv');
10: var_dump($fo->fgetcsv(',', '"', 'invalid'));
11: ?>
12: --CLEAN--
13: <?php
14: unlink('SplFileObject__fgetcsv.csv');
15: ?>
16: --EXPECTF--
17: Warning: SplFileObject::fgetcsv(): escape must be a character in %s on line %d
18: bool(false)
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>