File tree Expand file tree Collapse file tree 1 file changed +38
-0
lines changed Expand file tree Collapse file tree 1 file changed +38
-0
lines changed Original file line number Diff line number Diff line change
1
+ --TEST--
2
+ Test extension info
3
+ --SKIPIF--
4
+ <?php include (__DIR__ . '/../skipif.inc ' ); ?>
5
+ --FILE--
6
+ <?php
7
+
8
+ function contains ($ input , $ expected ) {
9
+ return strpos ($ input , $ expected ) !== false
10
+ ? $ expected
11
+ : 'not contains ' ;
12
+ }
13
+
14
+ $ version = phpversion ('Zephir Parser ' );
15
+ $ actual = trim (file_get_contents (__DIR__ . '/../../VERSION ' ));
16
+
17
+ $ compare = $ version === $ actual ;
18
+ var_dump ($ compare );
19
+
20
+ ob_start ();
21
+ phpinfo (INFO_MODULES );
22
+ $ info = trim (ob_get_clean ());
23
+
24
+ echo contains ($ info , 'Zephir Parser ' ).PHP_EOL ;
25
+ echo contains ($ info , 'The Zephir Parser delivered as a C extension for the PHP language. ' ).PHP_EOL ;
26
+ echo contains ($ info , 'Zephir Parser => enabled ' ).PHP_EOL ;
27
+ echo contains ($ info , 'Author => Zephir Team and contributors ' ).PHP_EOL ;
28
+ echo contains ($ info , 'Version => ' ).PHP_EOL ;
29
+ echo contains ($ info , 'Build Date => ' ).PHP_EOL ;
30
+ ?>
31
+ --EXPECT--
32
+ bool(true)
33
+ Zephir Parser
34
+ The Zephir Parser delivered as a C extension for the PHP language.
35
+ Zephir Parser => enabled
36
+ Author => Zephir Team and contributors
37
+ Version =>
38
+ Build Date =>
You can’t perform that action at this time.
0 commit comments