xref: /PHP-7.0/ext/spl/tests/bug64782.phpt (revision 1cb4398a)
1--TEST--
2Bug #64782: SplFileObject constructor make $context optional / give it a default value
3--FILE--
4<?php
5
6var_dump(new SplFileObject(__FILE__, "r", false, null));
7
8?>
9--EXPECTF--
10object(SplFileObject)#1 (%d) {
11  ["pathName":"SplFileInfo":private]=>
12  string(%d) "%sbug64782.php"
13  ["fileName":"SplFileInfo":private]=>
14  string(12) "bug64782.php"
15  ["openMode":"SplFileObject":private]=>
16  string(1) "r"
17  ["delimiter":"SplFileObject":private]=>
18  string(1) ","
19  ["enclosure":"SplFileObject":private]=>
20  string(1) """
21}
22