Annotation of embedaddon/php/ext/standard/tests/math/dechex_basic.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Test dechex() - basic function dechex()
3: --FILE--
4: <?php
5: $values = array(10,
6: 3950.5,
7: 3.9505e3,
8: 039,
9: 0x5F,
10: "10",
11: "3950.5",
12: "3.9505e3",
13: "039",
14: "0x5F",
15: true,
16: false,
17: null,
18: );
19:
20: for ($i = 0; $i < count($values); $i++) {
21: $res = dechex($values[$i]);
22: var_dump($res);
23: }
24: ?>
25: --EXPECTF--
26: string(1) "a"
27: string(3) "f6e"
28: string(3) "f6e"
29: string(1) "3"
30: string(2) "5f"
31: string(1) "a"
32: string(3) "f6e"
33: string(1) "3"
34: string(2) "27"
35: string(1) "0"
36: string(1) "1"
37: string(1) "0"
38: string(1) "0"
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>