1--TEST--
2Test strnatcasecmp() function : basic functionality
3--CREDITS--
4Felix De Vliegher <felix.devliegher@gmail.com>
5--FILE--
6<?php
7function str_dump($one, $two) {
8    var_dump(strnatcasecmp($one, $two));
9}
10
11echo "*** Testing strnatcasecmp() : basic functionality ***\n";
12
13// Calling strnatcasecmp() with all possible arguments
14str_dump('A', 'a');
15str_dump('a10', 'A20');
16str_dump('A1b', 'a');
17str_dump('x2-y7', 'x8-y8');
18str_dump('1.010', '1.001');
19str_dump(' ab', ' aB');
20str_dump('acc ', 'acc');
21str_dump(11.5, 10.5);
22str_dump(10.5, 10.5E1);
23str_dump('Rfc822.txt', 'rfc2086.txt');
24str_dump('Rfc822.txt', 'rfc822.TXT');
25str_dump('pIc 6', 'pic   7');
26str_dump(0xFFF, 0Xfff);
27
28?>
29--EXPECT--
30*** Testing strnatcasecmp() : basic functionality ***
31int(0)
32int(-1)
33int(1)
34int(-1)
35int(1)
36int(0)
37int(1)
38int(1)
39int(-1)
40int(-1)
41int(0)
42int(-1)
43int(0)
44