Annotation of embedaddon/php/ext/standard/tests/file/touch_variation2.phpt, revision 1.1.1.1

1.1       misho       1: --TEST--
                      2: touch() - ensure touch does not delete existing file.
                      3: --CREDITS--
                      4: Dave Kelsey <d_kelsey@uk.ibm.com>
                      5: --FILE--
                      6: <?php
                      7: 
                      8: 
                      9: $filename = dirname(__FILE__)."/touch.dat";
                     10: $fp=fopen($filename,"w");
                     11: fwrite ($fp,"mydata");
                     12: fclose($fp);
                     13: 
                     14: var_dump(touch($filename, 101));
                     15: var_dump(file_get_contents($filename));
                     16: 
                     17: @unlink($filename);
                     18: echo "Done\n";
                     19: 
                     20: ?>
                     21: --EXPECT--     
                     22: bool(true)
                     23: string(6) "mydata"
                     24: Done

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>