Subversion-Projekte lars-tiefland.php_share

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
--TEST--
2
File_CSV Test Case bug5257: Delimiter problem if first field is empty
3
--FILE--
4
<?php
5
// $Id: bug5257.phpt,v 1.2 2007/05/11 21:49:01 cipri Exp $
6
/**
7
 * Test for:
8
 * - File_CSV::readQuoted()
9
 */
10
 
11
require_once 'File/CSV.php';
12
 
13
$file = dirname(__FILE__) . '/bug5257.csv';
14
$conf = File_CSV::discoverFormat($file);
15
 
16
print "Format:\n";
17
print_r(File_CSV::read($file, $conf));
18
print "\n";
19
print_r(File_CSV::read($file, $conf));
20
print "\n";
21
print_r(File_CSV::read($file, $conf));
22
print "\n";
23
print_r(File_CSV::read($file, $conf));
24
print "\n";
25
?>
26
--EXPECT--
27
Format:
28
Array
29
(
30
    [0] =>
31
    [1] => foo
32
)
33
 
34
Array
35
(
36
    [0] => foo
37
    [1] =>
38
)
39
 
40
Array
41
(
42
    [0] =>
43
    [1] => foo
44
)
45
 
46
Array
47
(
48
    [0] => foo
49
    [1] =>
50
)