diff options
Diffstat (limited to 'ext/standard/tests/general_functions/getservbyname_variation4.phpt')
-rwxr-xr-x | ext/standard/tests/general_functions/getservbyname_variation4.phpt | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/ext/standard/tests/general_functions/getservbyname_variation4.phpt b/ext/standard/tests/general_functions/getservbyname_variation4.phpt new file mode 100755 index 0000000000..6033c94363 --- /dev/null +++ b/ext/standard/tests/general_functions/getservbyname_variation4.phpt @@ -0,0 +1,31 @@ +--TEST-- +Test function getservbyname() by substituting argument 1 with float values. +--FILE-- +<?php + + +echo "*** Test substituting argument 1 with float values ***\n"; + +$protocol = "tcp"; + + +$variation_array = array( + 'float 10.5' => 10.5, + 'float -10.5' => -10.5, + 'float 12.3456789000e10' => 12.3456789000e10, + 'float -12.3456789000e10' => -12.3456789000e10, + 'float .5' => .5, + ); + + +foreach ( $variation_array as $var ) { + var_dump(getservbyname( $var , $protocol ) ); +} +?> +--EXPECTF-- +*** Test substituting argument 1 with float values *** +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) |