mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-12 19:50:50 +00:00
fix tests
This commit is contained in:
1 parent
da2a302e78
commit
ae5dcdccf2
7 files changed
+1443
-1328
No files matched your search
File diff suppressed because it is too large.
Load diff
@@ -1,5 +1,5 @@
|
||||
--TEST--
|
||||
Test fgetcsv() : usage variations - reading the blank line (Bug #42228)
|
||||
Test fgetcsv() : usage variations - reading the blank line
|
||||
--FILE--
|
||||
<?php
|
||||
/*
|
||||
@@ -56,6 +56,11 @@ $loop_counter = 1;
|
||||
// check the file pointer position and if eof
|
||||
var_dump( ftell($file_handle) );
|
||||
var_dump( feof($file_handle) );
|
||||
// reading again to struck EOF
|
||||
var_dump( fgetcsv($file_handle, 1024) );
|
||||
// check the file pointer position and if eof
|
||||
var_dump( ftell($file_handle) );
|
||||
var_dump( feof($file_handle) );
|
||||
|
||||
// close the file
|
||||
fclose($file_handle);
|
||||
@@ -74,6 +79,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using rb mode --
|
||||
@@ -82,6 +90,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using rt mode --
|
||||
@@ -90,6 +101,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using r+ mode --
|
||||
@@ -98,6 +112,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using r+b mode --
|
||||
@@ -106,6 +123,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using r+t mode --
|
||||
@@ -114,6 +134,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using a+ mode --
|
||||
@@ -122,6 +145,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using a+b mode --
|
||||
@@ -130,6 +156,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using a+t mode --
|
||||
@@ -138,6 +167,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using w+ mode --
|
||||
@@ -146,6 +178,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using w+b mode --
|
||||
@@ -154,6 +189,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using w+t mode --
|
||||
@@ -162,6 +200,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using x+ mode --
|
||||
@@ -170,6 +211,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using x+b mode --
|
||||
@@ -178,6 +222,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using x+t mode --
|
||||
@@ -186,6 +233,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
Done
|
||||
|
||||
@@ -198,6 +248,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using rb mode --
|
||||
@@ -206,6 +259,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using rt mode --
|
||||
@@ -215,6 +271,9 @@ array(1) {
|
||||
}
|
||||
int(1)
|
||||
bool(true)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using r+ mode --
|
||||
array(1) {
|
||||
@@ -222,6 +281,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using r+b mode --
|
||||
@@ -230,6 +292,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using r+t mode --
|
||||
@@ -239,6 +304,9 @@ array(1) {
|
||||
}
|
||||
int(1)
|
||||
bool(true)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using a+ mode --
|
||||
array(1) {
|
||||
@@ -246,6 +314,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using a+b mode --
|
||||
@@ -254,6 +325,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using a+t mode --
|
||||
@@ -263,6 +337,9 @@ array(1) {
|
||||
}
|
||||
int(1)
|
||||
bool(true)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using w+ mode --
|
||||
array(1) {
|
||||
@@ -270,6 +347,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using w+b mode --
|
||||
@@ -278,6 +358,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using w+t mode --
|
||||
@@ -287,6 +370,9 @@ array(1) {
|
||||
}
|
||||
int(1)
|
||||
bool(true)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using x+ mode --
|
||||
array(1) {
|
||||
@@ -294,6 +380,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using x+b mode --
|
||||
@@ -302,6 +391,9 @@ array(1) {
|
||||
string(0) ""
|
||||
}
|
||||
int(1)
|
||||
bool(false)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
|
||||
-- Testing fgetcsv() with file opened using x+t mode --
|
||||
@@ -311,4 +403,7 @@ array(1) {
|
||||
}
|
||||
int(1)
|
||||
bool(true)
|
||||
bool(false)
|
||||
int(1)
|
||||
bool(true)
|
||||
Done
|
||||
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user