Commit Graph

340 Commits

Author SHA1 Message Date
Antony Dovgal
1857da91b4 fix *scanf() tests 2006-12-27 15:26:13 +00:00
Antony Dovgal
7ea07ff6dc MFB tests (they still fail though)
fix BC in fgetss()
2006-12-07 23:00:45 +00:00
Antony Dovgal
024d8f4376 cosmetic improvements 2006-12-05 23:03:42 +00:00
Sara Golemon
78f65cc451 Unicode upgrade for fgetcsv() 2006-12-05 04:13:47 +00:00
Antony Dovgal
9ed4f515d1 fix #39673 (file_get_contents causes bus error on certain offsets) 2006-11-29 11:10:49 +00:00
Pierre Joye
19abc4b507 - #39538, fgetcsv can't handle starting newlines and trailing odd
number of backslashes (David Soria Parra, Pierre)
2006-11-22 12:56:26 +00:00
Antony Dovgal
8373efc9b9 fix #39551 (Segfault with stream_bucket_new in user filter)
also fixes several segfaults and leaks
add test
2006-11-21 15:47:44 +00:00
Antony Dovgal
b198d2d028 fix test on Solaris 2006-11-20 16:28:14 +00:00
Antony Dovgal
c41f14297c fix tests (add missing SKIPIF sections and a fix for FreeBSD) 2006-11-16 13:49:01 +00:00
Antony Dovgal
107229611b more new tests, yikes! 2006-11-16 13:00:03 +00:00
Antony Dovgal
1063fa6a90 add new tests 2006-11-15 22:42:28 +00:00
Antony Dovgal
bbc854a4bd add new tests 2006-11-15 17:26:54 +00:00
Antony Dovgal
a92ccf9ab1 fix test on AIX 2006-11-15 12:11:07 +00:00
Antony Dovgal
f9847c0d0e fix test 2006-11-15 11:27:10 +00:00
Antony Dovgal
af43feda28 fix test 2006-11-15 10:48:30 +00:00
Antony Dovgal
f9d4063fed one more test 2006-11-14 22:23:23 +00:00
Antony Dovgal
41bb09b30d add new tests 2006-11-14 21:59:02 +00:00
Antony Dovgal
8c5c0ce29c fix test and prevent endless loop 2006-11-09 00:33:54 +00:00
Hannes Magnusson
5e9c0be4f8 Remove SKIPIF 2006-11-03 14:17:17 +00:00
Antony Dovgal
7bf64871c9 add new test by Pierre 2006-10-19 12:06:57 +00:00
Antony Dovgal
729ed6eafc fix crash when parsing invalid hostnames/IPs 2006-10-11 12:53:38 +00:00
Sara Golemon
1aa537ebd4 Update (most of) the functions in streamsfuncs.c
This commit also includes a change to tests/file/stream_rfc2397_002.phpt
which doesn't entirely pass in unicode mode yet, however that's a unicode
issue in the data:// wrapper that needs fixing, not a problem with the
streams layer itself.
2006-09-21 19:53:10 +00:00
Antony Dovgal
e264e460a4 fix double free(), add test 2006-09-15 07:26:19 +00:00
Antony Dovgal
c1b3a17034 new tests 2006-08-15 08:53:55 +00:00
Antony Dovgal
3cf1565d90 typos in comments and other minor improvements 2006-08-10 13:44:00 +00:00
Antony Dovgal
20b0975a43 fix test
I really hope there are no systems where /dev is a symlink
2006-07-28 13:47:41 +00:00
Antony Dovgal
12f44c2b2b fix #38086 (stream_copy_to_stream() returns 0 when maxlen is bigger than the actual length) 2006-07-13 11:58:42 +00:00
Antony Dovgal
f41a4f4546 /tmp is often a symlink, use /bin instead 2006-07-11 21:19:56 +00:00
Hannes Magnusson
d03ba9cdc5 fix test 2006-06-29 14:53:31 +00:00
Nuno Lopes
b5fda0101c MFB 5.2 2006-06-20 21:58:03 +00:00
Hannes Magnusson
1cb807ab63 Renamed file to bug37864.phpt 2006-06-20 19:31:04 +00:00
Hannes Magnusson
2c87f890bc Test for bug #37864 (file_get_contents() leaks on empty file) 2006-06-20 19:30:19 +00:00
Antony Dovgal
bc5a9692cb don't leave garbage in tmp dir 2006-06-20 18:55:37 +00:00
Hannes Magnusson
f3334c8df3 add test for file_get_contents() leaking on empty file 2006-06-20 18:46:14 +00:00
Sara Golemon
a8ca40564c Minor fixes (bjori) 2006-05-30 19:05:21 +00:00
Antony Dovgal
11b66c6cec add test 2006-05-29 10:42:37 +00:00
Marcus Boerger
47343620cb - Add new test 2006-05-23 22:26:55 +00:00
Marcus Boerger
a4d6c5a6f0 - Handle corrupt base64 data in data: url 2006-05-21 13:35:06 +00:00
Antony Dovgal
17c98844d5 new mkdir tests 2006-05-16 13:07:07 +00:00
Marcus Boerger
3856d8da6d - Add strict compliant RFC2397 support (no //) 2006-05-14 18:35:40 +00:00
Marcus Boerger
3b66ab74f9 - RFC2397 add decoding
# done (need to decide whether all examples shouldl work or specs are
# followed)
2006-05-14 01:39:24 +00:00
Marcus Boerger
73069100fd - Change to use dedicated stream ops 2006-05-14 00:45:27 +00:00
Marcus Boerger
4f29479a22 - RFC 2397 meta data handling 2006-05-14 00:40:53 +00:00
Marcus Boerger
29c0f5bede - Initial RFC2397 support
# decoding is missing right now
2006-05-13 17:53:01 +00:00
Antony Dovgal
8a434f5df0 merge fix for #37158 into HEAD
add test
2006-04-22 23:49:39 +00:00
Ilia Alshanetsky
490609ffc4 MFB51: fixed test 2006-04-10 23:48:38 +00:00
Sara Golemon
b6f62cabff Silence false positives on test results 2006-04-06 20:03:27 +00:00
Sara Golemon
78d1f7ea40 Silence false positives in test failures 2006-04-06 19:51:36 +00:00
Antony Dovgal
1df7e13f48 fix #36741 (userstreams testcase have off-by-one error on fseek()) 2006-03-20 22:08:59 +00:00
Pierre Joye
bb1ec86f9d - remove magic_quotes_gpc, magic_quotes_runtime, magic_quotes_sybase
(calling ini_set('magic_....') returns 0|false
- get_magic_quotes_gpc, get_magic_quotes_runtime are kept but always return false
- set_magic_quotes_runtime raises an E_CORE_ERROR
2006-03-08 00:43:32 +00:00
Ilia Alshanetsky
a605fd39c4 More safe_mode nuking 2006-02-19 18:20:51 +00:00
Antony Dovgal
1c7661a301 MFB: fix #35781 (stream_filter_append() can cause segfault) 2005-12-23 15:05:42 +00:00
Antony Dovgal
8f5f3d8408 MFB: add test for #35740 2005-12-20 09:52:05 +00:00
Dmitry Stogov
4192685b64 Fixed bug #35393 (changing static protected members from outside the class, one more reference issue) 2005-11-28 14:33:44 +00:00
Dmitry Stogov
45699741e1 Fixed fgetcsv() and fputcsv() inconsistency. 2005-10-21 12:14:11 +00:00
Dmitry Stogov
8f6f97a77d Unicode support 2005-08-23 12:53:31 +00:00
Andrei Zmievski
264cec8be6 Unicode support. 2005-08-11 23:36:07 +00:00
Ilia Alshanetsky
c933634253 Fixed crash inside stream_get_line() when length parameter equals 0. 2005-07-05 19:24:07 +00:00
Ilia Alshanetsky
49c233212b Fixed bug #32160 (copying a file into itself leads to data loss). 2005-06-22 16:13:47 +00:00
foobar
a104447d46 Make sure $_ENV is populated 2005-06-18 02:24:37 +00:00
Wez Furlong
867e619154 add test for bug 27508 2005-05-11 02:01:44 +00:00
foobar
2887f89075 remove empty lines 2005-04-04 18:14:27 +00:00
foobar
28b13f50e6 Added testcase for bug #30362 2005-04-04 18:06:16 +00:00
Marcus Boerger
32e478b9fc - Add fputcsv() (David Sklar) 2004-09-26 21:55:22 +00:00
Marcus Boerger
29cfd6d24f - Remove unused blocks 2004-05-19 08:56:50 +00:00
Sara Golemon
72616e6eae BugFix#27619
Filters not applied to pre-buffered stream data.
(esp. http:// streams)
2004-03-31 23:48:59 +00:00
Sara Golemon
4341ee6061 Userspace Directory Stream Test 2004-03-17 20:48:12 +00:00
Wez Furlong
0619eee6d0 test case for statcache corruption of BG 2004-02-23 21:07:10 +00:00
foobar
8cd863f738 test case for bug #26938 2004-01-21 22:48:28 +00:00
Sara Golemon
1fb629de8a Typo 2004-01-21 04:08:10 +00:00
Ilia Alshanetsky
608db4728b Added fgetcsv() tests. 2004-01-19 03:55:29 +00:00
Moriyoshi Koizumi
27f47eb173 "seq" isn't available for all platforms. 2004-01-04 03:06:11 +00:00
Sara Golemon
4af0ba44d9 Test additional wrapper methods [unlink, rename, mkdir, rmdir, url_stat] 2003-12-28 01:06:38 +00:00
Derick Rethans
112f424f70 - Fixed bug #26615 (patch by runekl at opoint dot com) 2003-12-13 18:55:53 +00:00
Marcus Boerger
c3fddcab62 Fix tests for E_STRICT and check for E_STRICT in run-tests.php. 2003-11-30 13:57:20 +00:00
Moriyoshi Koizumi
6b7bd4be8f ctime (#10) may differ on several filesystems.
# I confirmed it on Darwin
2003-11-14 08:59:30 +00:00
Moriyoshi Koizumi
28369f6e86 Add test case for bug #26003 2003-10-29 19:45:38 +00:00
Ilia Alshanetsky
4d349926ff Fixed some test names.
Removed extraneous \r from a number of tests.
2003-10-24 03:31:57 +00:00
Moriyoshi Koizumi
5dac05638f Fix typo 2003-10-20 15:45:01 +00:00
Ilia Alshanetsky
c23609efa7 Fixed paths in various tests. In certain conditions usage of partial file
paths results in test failures.
2003-08-18 22:57:49 +00:00
Hartmut Holzgraefe
b0a4e1a2d2 whitespace 2003-07-15 17:28:41 +00:00
Hartmut Holzgraefe
2f5a3b4c63 #1 $_ENV is not always set, use getenv() instead
#2 bail out after 1000 loop iterations to avoid hanging tests
2003-07-15 16:55:44 +00:00
foobar
94a19d1bc6 Make this test work regardless of safe_mode setting (bug #24654) 2003-07-15 07:06:42 +00:00
Moriyoshi Koizumi
d33ffb78aa Added regression test for proc_open() 2003-07-13 08:03:46 +00:00
Hartmut Holzgraefe
de6a6ed6d7 skip test if glob() is not available at all 2003-07-04 15:07:11 +00:00
Hartmut Holzgraefe
3c34e4edaf regression test for #24482 GLOB_ONLYDIR is not working (on BSD) 2003-07-04 14:38:07 +00:00
Moriyoshi Koizumi
181508a837 s/cvs/csv/ 2003-07-02 17:07:56 +00:00
Moriyoshi Koizumi
ed033faaec s/cvs/csv/ :) 2003-07-02 15:43:44 +00:00
Ilia Alshanetsky
a6fd611c5e Added array handling to file_put_contents()
More verbose error reporting mechanism.
Test case for file_put_contents().
2003-06-28 20:06:13 +00:00
Ilia Alshanetsky
6b5b6079da Fix for bug #24313 (port from dead PHP_5 branch) 2003-06-24 13:56:25 +00:00
Derick Rethans
92f0da58e6 - Rename stream_register_filter() to stream_filter_register(),
stream_register_wrapper() to stream_wrapper_register() and added an alias for
  the latter change.
2003-05-19 15:35:06 +00:00
foobar
422309353d CS 2003-05-18 14:55:18 +00:00
Moriyoshi Koizumi
80c75c4d62 MFB(r-1.1.2.7): fix test 2003-05-17 20:06:00 +00:00
Moriyoshi Koizumi
f78ec11339 Fixed test so it won't fail in case the output handler is enabled 2003-05-15 19:20:31 +00:00
Ilia Alshanetsky
6bc4ce43d0 Do not hardcode php path. 2003-04-19 18:10:54 +00:00
Ilia Alshanetsky
e4c38aec5a Do not make the test rely on the availability of the cat command. 2003-04-19 17:45:46 +00:00
Sara Golemon
c249c67178 New test for userfilters rewrite 2003-04-02 00:41:09 +00:00
Ilia Alshanetsky
b162e18a29 Skip test if running under safe-mode. 2003-03-04 14:37:38 +00:00
Ilia Alshanetsky
503e49feae Fixed test. 2003-02-25 16:27:51 +00:00
Ilia Alshanetsky
f29964e2ba Fixed bug #22414 and added a test case for it. 2003-02-25 16:21:00 +00:00
Ilia Alshanetsky
a3cb589b71 Fixed bug #22382 (fgetcsv did not handle \" correctly). 2003-02-24 03:13:25 +00:00
Wez Furlong
32c1eafe85 Remove bogus test.
Append mode always causes written data to go to the end of the file,
regardless of the current seek position.
2003-02-16 15:42:14 +00:00
Kai Schroeder
e42339a6b4 shane added is_executable() for windows last night 2003-02-09 13:54:01 +00:00
Kai Schroeder
d1338ff914 reverting to version 1.5; shane added is_executable() for windows last night 2003-02-09 13:52:46 +00:00
Kai Schroeder
11e81f89fd there are no symlinks on Windows 2003-02-09 13:20:17 +00:00
Kai Schroeder
ea9101135f is_executable() does not exist on Windows 2003-02-09 13:19:23 +00:00
Wez Furlong
d23d4b366d Make it slightly more obvious that the return value is relative to the length
of the input data.
2003-01-06 14:04:23 +00:00
Wez Furlong
f58628ca4d Move rot13 filter into a new filters.c source file.
Tidy up some other filter related code.

# win32 -> someone please add user_filters.c and filters.c to the .dsp
2003-01-01 11:04:44 +00:00
Wez Furlong
350b0bbeac Implement user-space filters.
See ext/standard/tests/file/userfilters.phpt for an example of their use.
2002-12-31 18:39:36 +00:00
Wez Furlong
c5091eedf1 Forgot to include this in my previous commit for #21131 fix. 2002-12-22 18:06:27 +00:00
Wez Furlong
efea12fec5 Fix for Bug #21131: fopen($file, 'a+') would incorrectly assume that
the stream position was at offset 0.
This corrects that assumption by querying the stream for it's position
when it detects the 'a' "flag" in the mode parameter to fopen.
Also added a test for plain files and amended the userstreams test to
take this into account.
2002-12-22 18:05:36 +00:00
Moriyoshi Koizumi
d2fa4670dc Prevented test failure caused by LF code variety 2002-12-18 23:06:27 +00:00
Ilia Alshanetsky
7364e3b771 Fixed bug #12556, updated the test for this bug. 2002-12-05 20:01:19 +00:00
Melvyn Sopacua
bd06d48e56 Test data 2002-12-05 19:30:28 +00:00
Melvyn Sopacua
76436b8820 Add a testcase for this bug 2002-12-05 19:29:45 +00:00
Wez Furlong
4e85935386 MFB 2002-11-14 14:26:15 +00:00
Wez Furlong
b01add793c Add this test to make sure that fopencookie is detected and working
correctly (or that the less efficient tmpfile casting is working).
More details in the test itself.
2002-11-14 12:20:36 +00:00
Derick Rethans
bab4957d1c - MFB: Fixed bug #20484 (stream_get_meta_data crashes on a normal file
stream). (Derick, Wez)
2002-11-14 10:56:35 +00:00
Wez Furlong
a4a517015e I like my C comments, thanks very much. 2002-10-29 14:36:49 +00:00
Wez Furlong
2d2a375fa6 length of lyrics is not part of the test. 2002-10-29 14:31:54 +00:00
Marcus Boerger
82317945e5 -WS
-Use "//" instead of "/* ... */" comments
#this test fails for me. Very weired...
2002-10-29 14:05:55 +00:00
foobar
e232b212ba There is no point doing this test. Some systems think root can always execute so this is always true. 2002-10-21 00:30:05 +00:00
Wez Furlong
39f8d4c971 Add a sanity check and more verbose output in the case of an error. 2002-10-14 02:25:51 +00:00
Derick Rethans
8f7f6045b0 - Make the test do what it says 2002-10-12 16:53:13 +00:00
Wez Furlong
077fe52d8b This seems to resolve the issues with fgets.
I've moved EOF detection into the streams layer; a stream reader
implementation should set stream->eof when it detects EOF.
Fixed test for user streams - it still fails but that is due to an output
buffering bug.
2002-10-05 10:35:13 +00:00
Wez Furlong
7694770304 Rename streams functions to fit with naming conventions, adding aliases
for old functions where required.
Make use of recent changes to chunk size and timeout setting code.
2002-09-28 22:14:21 +00:00
Wez Furlong
9e84b3d5b5 Revise buffer/seek code a little.
Tidy up user streams even more.
Make test case quite aggressive.
2002-09-23 13:22:10 +00:00
Wez Furlong
ff7bece5bb Tidy up some user stream code.
Add a small test case (not yet complete).
2002-09-18 10:15:40 +00:00
foobar
2f12941fac - Made all is_*() functions to return only boolean values.
- Killed the "file not found" error for is_link(). (finally..)
2002-05-16 01:07:21 +00:00
foobar
3b1ae7c62a revert last bogus change. There is bug in is_file() 2002-04-30 10:38:06 +00:00
Wez Furlong
840ed90f2b Fix is_file test.
# Is there a good reason for having the actual test in an include file??
2002-04-30 00:26:49 +00:00
Yasuo Ohgaki
de4a0ba58e Add test case for file_exist/is_file 2002-04-28 00:05:43 +00:00
Marcus Boerger
42dc682626 fix testproblem 2002-04-11 06:41:55 +00:00
Wez Furlong
4361807185 add test for file_get_contents 2002-03-28 01:20:28 +00:00
Derick Rethans
39225a22b8 - Fix tests to work with CLI
#- Not totally done, but this makes it a lot better
2002-03-05 09:00:56 +00:00
Rasmus Lerdorf
f78f4364a0 Different operating systems handle the group x bit differently, so
simplify this test to test the user x bit instead
2001-11-13 12:39:21 +00:00
Sascha Schumann
d6d59a9ee5 1. st_blksize might be different for regular files and symlinks; hence
ignore differences in the twelfth element of the stat() array.

2. The 'test.file' is created by the script, thus the owner of the file
   is the user id executing the script.  A mode of 0654 does not grant
   the owner the right to execute the file and therefore, the correct
   output here is "not executable."
2001-06-21 11:15:38 +00:00
Jason Greene
7f3291ae8c Fix is_executable test. 2001-05-11 02:45:49 +00:00
Stig Bakken
1bb90f5805 * all tests should pass now (expect for the interbase stuff that I haven't
had the chance to test)
2000-08-31 22:21:47 +00:00
Stig Bakken
315f4f5658 @PHP 3 regression testing framework re-born (Stig)
Took the old PHP 3 regression testing framework and rewrote it in PHP.
Should work on both Windows and UNIX, however I have not tested it on
Windows.  See tests/README for how to write tests.  Added the PHP 3
tests and converted most of them.
2000-08-27 19:46:06 +00:00