Skip to content

Commit

Permalink
fix tests according to new output of print_r
Browse files Browse the repository at this point in the history
  • Loading branch information
manuel-rubio committed May 28, 2015
1 parent cddef0f commit 30a5ad7
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 8 deletions.
4 changes: 2 additions & 2 deletions test/code/test_array.out
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ $base => Array
[3] => 4
[4] => 5
[5] => Array
(
(
[0] => 8
[1] => 9
)
)
)
is 1 in array $base? yes
is 8 in array $base? no
Expand Down
4 changes: 4 additions & 0 deletions test/code/test_func_list.out
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
great! number of internal functions is greater than 10
great! there are not user functions registered yet
bool(true)
bool(false)
11 changes: 11 additions & 0 deletions test/code/test_func_list.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?php

$functions = get_defined_functions();
if (count($functions['internal']) > 10) {
print "great! number of internal functions is greater than 10\n";
}
if (count($functions['user']) == 0) {
print "great! there are not user functions registered yet\n";
}
var_dump(function_exists("strlen"));
var_dump(function_exists("function_not_exists_never"));
8 changes: 4 additions & 4 deletions test/code/test_print_r.out
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
<pre>Array
(
[0] => Array
(
(
[name] => Manuel
[surname] => Rubio
)
)
[1] => Array
(
(
[name] => Margarita
[surname] => Ortiz
)
)
)
</pre>
</body>
Expand Down
4 changes: 2 additions & 2 deletions test/code/test_unset.out
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
<pre>Array
(
[0] => Array
(
(
[name] => Manuel
[surname] => Rubio
)
)
)
</pre>
</body>
Expand Down
1 change: 1 addition & 0 deletions test/ephp_code_test.erl
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ code_to_test_() ->
"test_function_refs",
"test_func_var_dump",
"test_func_icase",
"test_func_list",
"test_literal",
"test_print_true",
"test_include",
Expand Down

0 comments on commit 30a5ad7

Please sign in to comment.