1--TEST--
2*_include_path() tests
3--INI--
4include_path=.
5--FILE--
6<?php
7
8var_dump(get_include_path());
9var_dump(get_include_path("var"));
10
11var_dump(restore_include_path());
12var_dump(restore_include_path(""));
13
14
15var_dump(set_include_path());
16var_dump(get_include_path());
17var_dump(set_include_path("var"));
18var_dump(get_include_path());
19
20var_dump(restore_include_path());
21var_dump(get_include_path());
22
23var_dump(set_include_path(".:/path/to/dir"));
24var_dump(get_include_path());
25
26var_dump(restore_include_path());
27var_dump(get_include_path());
28
29var_dump(set_include_path(""));
30var_dump(get_include_path());
31
32var_dump(restore_include_path());
33var_dump(get_include_path());
34
35var_dump(set_include_path(array()));
36var_dump(get_include_path());
37
38var_dump(restore_include_path());
39var_dump(get_include_path());
40
41
42echo "Done\n";
43?>
44--EXPECTF--
45string(1) "."
46
47Warning: get_include_path() expects exactly 0 parameters, 1 given in %s on line %d
48NULL
49NULL
50
51Warning: restore_include_path() expects exactly 0 parameters, 1 given in %s on line %d
52NULL
53
54Warning: set_include_path() expects exactly 1 parameter, 0 given in %s on line %d
55NULL
56string(1) "."
57string(1) "."
58string(3) "var"
59NULL
60string(1) "."
61string(1) "."
62string(14) ".:/path/to/dir"
63NULL
64string(1) "."
65bool(false)
66string(1) "."
67NULL
68string(1) "."
69
70Warning: set_include_path() expects parameter 1 to be a valid path, array given in %s on line %d
71NULL
72string(1) "."
73NULL
74string(1) "."
75Done
76