Annotation of embedaddon/php/ext/standard/tests/file/stream_001.phpt, revision 1.1
1.1 ! misho 1: --TEST--
! 2: stream_wrapper_unregister() & stream_wrapper_restore()
! 3: --FILE--
! 4: <?php
! 5:
! 6: var_dump(stream_wrapper_unregister('file'));
! 7: var_dump(fopen("file://".__FILE__, "r"));
! 8: var_dump(stream_wrapper_restore('file'));
! 9: var_dump(fopen("file://".__FILE__, "r"));
! 10:
! 11: echo "Done\n";
! 12: ?>
! 13: --EXPECTF--
! 14: bool(true)
! 15:
! 16: Warning: fopen(): Unable to find the wrapper "file" - did you forget to enable it when you configured PHP? in %s on line %d
! 17:
! 18: Warning: fopen(): file:// wrapper is disabled in the server configuration in %s on line %d
! 19:
! 20: Warning: fopen(file://%s): failed to open stream: no suitable wrapper could be found in %s on line %d
! 21: bool(false)
! 22: bool(true)
! 23: resource(%d) of type (stream)
! 24: Done
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>