From: Raghubansh Kumar Date: Wed, 8 Aug 2007 13:13:18 +0000 (+0000) Subject: New Testcases for fgetcsv() function X-Git-Tag: php-5.2.4RC2~65 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9bd00453598ef6baefc191d644ede998d6d8b504;p=php New Testcases for fgetcsv() function --- diff --git a/ext/standard/tests/file/fgetcsv_error.phpt b/ext/standard/tests/file/fgetcsv_error.phpt new file mode 100644 index 0000000000..c3ace9ab87 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_error.phpt @@ -0,0 +1,95 @@ +--TEST-- +Test fgetcsv() function : error conditions +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with all parameters specified *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation10.phpt b/ext/standard/tests/file/fgetcsv_variation10.phpt new file mode 100644 index 0000000000..2d00f9993e --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation10.phpt @@ -0,0 +1,1295 @@ +--TEST-- +Test fgetcsv() : usage variations - file pointer pointing to EOF (Bug #42175) +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with file pointer pointing to EOF *** + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(55) +bool(true) +bool(false) +int(55) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(57) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(59) +bool(true) +bool(false) +int(59) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(63) +bool(true) +bool(false) +int(63) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(false) +bool(false) +int(65) +bool(true) +bool(false) +int(65) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(false) +bool(false) +int(%d) +bool(true) +bool(false) +int(%d) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation11.phpt b/ext/standard/tests/file/fgetcsv_variation11.phpt new file mode 100644 index 0000000000..815ede6f01 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation11.phpt @@ -0,0 +1,1835 @@ +--TEST-- +Test fgetcsv() : usage variations - with different enclosure but same delimiter +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with different enclosure but same delimiter char *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(7) ""water"" + [1]=> + string(7) ""fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(7) "^water^" + [1]=> + string(7) "^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(7) "&water&" + [1]=> + string(7) "&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(6) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(5) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(5) "fruit" + [4]=> + string(3) "air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(9) { + [0]=> + string(0) "" + [1]=> + string(5) "water" + [2]=> + string(0) "" + [3]=> + string(0) "" + [4]=> + string(5) "fruit" + [5]=> + string(0) "" + [6]=> + string(0) "" + [7]=> + string(3) "air" + [8]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(6) { + [0]=> + string(6) "&""""&" + [1]=> + string(3) "&"&" + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(3) "&,&" + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +Done \ No newline at end of file diff --git a/ext/standard/tests/file/fgetcsv_variation12.phpt b/ext/standard/tests/file/fgetcsv_variation12.phpt new file mode 100644 index 0000000000..e513fe6761 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation12.phpt @@ -0,0 +1,957 @@ +--TEST-- +Test fgetcsv() : usage variations - two chars as enclosure & delimiter (various read and append modes) +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with two chars as enclosure & delimiter *** + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation13.phpt b/ext/standard/tests/file/fgetcsv_variation13.phpt new file mode 100644 index 0000000000..a00405b90b --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation13.phpt @@ -0,0 +1,189 @@ +--TEST-- +Test fgetcsv() : usage variations - with line without any csv fields + +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : reading the line which is without csv fields *** + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation14.phpt b/ext/standard/tests/file/fgetcsv_variation14.phpt new file mode 100644 index 0000000000..654d7728cb --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation14.phpt @@ -0,0 +1,189 @@ +--TEST-- +Test fgetcsv() : usage variations - reading the blank line (Bug #42228) +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : reading the blank line *** + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation15.phpt b/ext/standard/tests/file/fgetcsv_variation15.phpt new file mode 100644 index 0000000000..b36b88ed3f --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation15.phpt @@ -0,0 +1,940 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default enclosure *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation16.phpt b/ext/standard/tests/file/fgetcsv_variation16.phpt new file mode 100644 index 0000000000..904c422428 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation16.phpt @@ -0,0 +1,944 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure & length as 0 +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default enclosure & length as 0 *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation17.phpt b/ext/standard/tests/file/fgetcsv_variation17.phpt new file mode 100644 index 0000000000..a54f8da61e --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation17.phpt @@ -0,0 +1,1565 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure & length less than line size +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default enclosure & length less than line size *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(3) "fru" +} +int(9) +bool(false) +array(1) { + [0]=> + string(2) "it" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(3) "air" +} +int(20) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(60) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" + [2]=> + string(43) "" +This is line of text without csv fields + +" +} +int(61) +bool(true) +bool(false) +int(61) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation18.phpt b/ext/standard/tests/file/fgetcsv_variation18.phpt new file mode 100644 index 0000000000..19915e816f --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation18.phpt @@ -0,0 +1,690 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure and different delimiter +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default enclosure and different delimiter *** + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation19.phpt b/ext/standard/tests/file/fgetcsv_variation19.phpt new file mode 100644 index 0000000000..2e282e1701 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation19.phpt @@ -0,0 +1,841 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure & delimiter of two chars +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with default enclosure & delimiter of two chars *** + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water,fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(11) "water fruit" +} +int(12) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(13) "water "fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(19) "water\"fruit"\"air"" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "water\"fruit"\"""" +} +int(20) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation2.phpt b/ext/standard/tests/file/fgetcsv_variation2.phpt new file mode 100644 index 0000000000..fc5947df50 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation2.phpt @@ -0,0 +1,1413 @@ +--TEST-- +Test fgetcsv() : usage variations - with length as 0 (Bug #42175) +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with length as 0 *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(11) "water=fruit" + [1]=> + string(0) "" +} +int(16) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(3) { + [0]=> + string(11) "water-fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation20.phpt b/ext/standard/tests/file/fgetcsv_variation20.phpt new file mode 100644 index 0000000000..e96089e9ab --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation20.phpt @@ -0,0 +1,191 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure, line without any csv fields +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default enclosure, line without any csv fields *** + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(40) +bool(false) +Done \ No newline at end of file diff --git a/ext/standard/tests/file/fgetcsv_variation21.phpt b/ext/standard/tests/file/fgetcsv_variation21.phpt new file mode 100644 index 0000000000..69059bb2c9 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation21.phpt @@ -0,0 +1,191 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure, blank line +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default enclosure, blank line *** + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(0) "" +} +int(1) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation22.phpt b/ext/standard/tests/file/fgetcsv_variation22.phpt new file mode 100644 index 0000000000..54cef3af86 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation22.phpt @@ -0,0 +1,614 @@ +--TEST-- +Test fgetcsv() : usage variations - with default enclosure, file pointer pointing at end of file (Bug #42175) +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default enclosure, file pointer pointing at end of file *** + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation23.phpt b/ext/standard/tests/file/fgetcsv_variation23.phpt new file mode 100644 index 0000000000..b766f1e062 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation23.phpt @@ -0,0 +1,48 @@ +--TEST-- +Test fgetcsv() : usage variations - empty file +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : reading from file which is having zero content *** +bool(false) +int(0) +bool(false) +int(0) +bool(false) +int(0) +bool(false) +int(0) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation24.phpt b/ext/standard/tests/file/fgetcsv_variation24.phpt new file mode 100644 index 0000000000..89b6d03b90 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation24.phpt @@ -0,0 +1,671 @@ +--TEST-- +Test fgetcsv() : usage variations - two chars as enclosure & delimiter (various write modes) +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with two chars as enclosure & delimiter *** + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Notice: fgetcsv(): delimiter must be a single character in %s on line %d + +Notice: fgetcsv(): enclosure must be a single character in %s on line %d +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation25.phpt b/ext/standard/tests/file/fgetcsv_variation25.phpt new file mode 100644 index 0000000000..1877bc0a0e --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation25.phpt @@ -0,0 +1,935 @@ +--TEST-- +Test fgetcsv() : usage variations - with negative length value along with enclosure and delimiter +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with negative length value *** + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation26.phpt b/ext/standard/tests/file/fgetcsv_variation26.phpt new file mode 100644 index 0000000000..c042eb4931 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation26.phpt @@ -0,0 +1,441 @@ +--TEST-- +Test fgetcsv() : usage variations - reading files opened in write only mode (Bug #42036) +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : reading the files opened in write only mode *** + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using wt mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using ab mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using at mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xb mode -- +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using xt mode -- +bool(false) +int(0) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation27.phpt b/ext/standard/tests/file/fgetcsv_variation27.phpt new file mode 100644 index 0000000000..aafc3ab6c9 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation27.phpt @@ -0,0 +1,935 @@ +--TEST-- +Test fgetcsv() : usage variations - with negative length value along with delimiter and no enclosure +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with negative length value *** + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation28.phpt b/ext/standard/tests/file/fgetcsv_variation28.phpt new file mode 100644 index 0000000000..56dd538ac1 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation28.phpt @@ -0,0 +1,935 @@ +--TEST-- +Test fgetcsv() : usage variations - with negative length value along with neither enclosure and nor delimiter +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with negative length value *** + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): Length parameter may not be negative in %s on line %d +bool(false) +int(0) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation29.phpt b/ext/standard/tests/file/fgetcsv_variation29.phpt new file mode 100644 index 0000000000..6ca5e87a1e --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation29.phpt @@ -0,0 +1,615 @@ +--TEST-- +Test fgetcsv() : usage variations - with only file handle as argument, file pointer pointing at end of file (Bug #42175) +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with file handle as only argument and file pointer pointing at end of file *** + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation3.phpt b/ext/standard/tests/file/fgetcsv_variation3.phpt new file mode 100644 index 0000000000..52c094faa5 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation3.phpt @@ -0,0 +1,933 @@ +--TEST-- +Test fgetcsv() : usage variations - with delimiter as NULL +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with delimiter as NULL *** + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation30.phpt b/ext/standard/tests/file/fgetcsv_variation30.phpt new file mode 100644 index 0000000000..c6e514da37 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation30.phpt @@ -0,0 +1,614 @@ +--TEST-- +Test fgetcsv() : usage variations - with file handle and length, file pointer pointing at end of file (Bug #42175) +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with file handle and length arguments, file pointer pointing at end of file *** + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation31.phpt b/ext/standard/tests/file/fgetcsv_variation31.phpt new file mode 100644 index 0000000000..5e042ac62d --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation31.phpt @@ -0,0 +1,616 @@ +--TEST-- +Test fgetcsv() : usage variations - with length and enclosure, file pointer pointing at end of file (Bug #42175) +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with enclosure argument, file pointer pointing at end of file *** + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(53) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(57) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rb mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using rt mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using r+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using a+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using w+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+ mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+b mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) + +-- Testing fgetcsv() with file opened using x+t mode -- +int(0) +bool(true) +bool(false) +int(61) +bool(true) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation4.phpt b/ext/standard/tests/file/fgetcsv_variation4.phpt new file mode 100644 index 0000000000..0c84484721 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation4.phpt @@ -0,0 +1,932 @@ +--TEST-- +Test fgetcsv() : usage variations - with enclosure as NULL +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with enclosure as NULL *** + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): enclosure must be a character in %s on line %d +bool(false) +int(0) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation5.phpt b/ext/standard/tests/file/fgetcsv_variation5.phpt new file mode 100644 index 0000000000..283fa40bd8 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation5.phpt @@ -0,0 +1,934 @@ +--TEST-- +Test fgetcsv() : usage variations - with delimiter & enclosure as NULL +--FILE-- + +--EXPECTF-- +*** Testing fgetcsv() : with delimiter & enclosure as NULL *** + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- + +Warning: fgetcsv(): delimiter must be a character in %s on line %d +bool(false) +int(0) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation6.phpt b/ext/standard/tests/file/fgetcsv_variation6.phpt new file mode 100644 index 0000000000..9878cb98d2 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation6.phpt @@ -0,0 +1,2350 @@ +--TEST-- +Test fgetcsv() : usage variations - with length less than line size +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with length less than line size *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(1) "f" +} +int(9) +bool(false) +array(1) { + [0]=> + string(4) "ruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(8) { + [0]=> + string(4) "This" + [1]=> + string(2) "is" + [2]=> + string(4) "line" + [3]=> + string(2) "of" + [4]=> + string(4) "text" + [5]=> + string(7) "without" + [6]=> + string(3) "csv" + [7]=> + string(6) "fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(56) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(6) "water=" +} +int(9) +bool(false) +array(2) { + [0]=> + string(5) "fruit" + [1]=> + string(0) "" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(58) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(6) "water-" +} +int(9) +bool(false) +array(3) { + [0]=> + string(5) "fruit" + [1]=> + string(3) "air" + [2]=> + string(0) "" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(6) { + [0]=> + string(4) """""" + [1]=> + string(1) """ + [2]=> + string(1) "," + [3]=> + string(1) """ + [4]=> + string(1) "," + [5]=> + string(4) ",,,," +} +int(24) +bool(false) +array(1) { + [0]=> + string(39) "This is line of text without csv fields" +} +int(64) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation7.phpt b/ext/standard/tests/file/fgetcsv_variation7.phpt new file mode 100644 index 0000000000..723328e086 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation7.phpt @@ -0,0 +1,1292 @@ +--TEST-- +Test fgetcsv() : usage variations - with default arguments value +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with default arguments value *** + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(2) { + [0]=> + string(5) "water" + [1]=> + string(5) "fruit" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(7) { + [0]=> + string(11) "&""""&:&"&:" + [1]=> + string(4) ":":&" + [2]=> + string(2) "&:" + [3]=> + string(0) "" + [4]=> + string(0) "" + [5]=> + string(0) "" + [6]=> + string(0) "" +} +int(24) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation8.phpt b/ext/standard/tests/file/fgetcsv_variation8.phpt new file mode 100644 index 0000000000..21b6c88752 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation8.phpt @@ -0,0 +1,1058 @@ +--TEST-- +Test fgetcsv() : usage variations - with different delimiter and enclosure +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with different delimiter and enclosure *** + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(13) ""water",fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(15) ""water","fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(15) "^water^ ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(15) "&water&:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(15) "=water===fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(17) "-water--fruit-air" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(21) "-water---fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(23) "&""""&:&"&:,:":&,&:,,,," +} +int(24) +bool(false) +Done diff --git a/ext/standard/tests/file/fgetcsv_variation9.phpt b/ext/standard/tests/file/fgetcsv_variation9.phpt new file mode 100644 index 0000000000..6400fc84e3 --- /dev/null +++ b/ext/standard/tests/file/fgetcsv_variation9.phpt @@ -0,0 +1,1056 @@ +--TEST-- +Test fgetcsv() : usage variations - with different delimiter but same enclosure +--FILE-- + +--EXPECT-- +*** Testing fgetcsv() : with different delimiter but same enclosure *** + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(11) "water,fruit" +} +int(14) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(13) "water,"fruit"" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(13) "water ^fruit^" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(13) "water:&fruit&" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(12) "water=fruit=" +} +int(16) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(14) "water-fruitair" +} +int(18) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(18) "water-fruit---air-" +} +int(22) +bool(false) + +-- Testing fgetcsv() with file opened using r mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rb mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using rt mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+ mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+b mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using r+t mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+ mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+b mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using a+t mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+ mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+b mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using w+t mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+ mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+b mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) + +-- Testing fgetcsv() with file opened using x+t mode -- +array(1) { + [0]=> + string(21) """"":&"&:,:":&,&:,,,," +} +int(24) +bool(false) +Done