Debian Codegraph @

t/7compare/v3_v0.t

raw
1 #
2 # compare v3 to v0.
3 #
4 use strict;
5 use warnings;
6 use MyTest;
7 use UUID ':all';
8
9 ok 1, 'loaded';
10
11 {# binary
12 generate_v3(my $u3, dns => 'www.example.com');
13 generate_v0(my $u0);
14 ok is_null($u0), 'is null';
15 isnt $u3, $u0, 'binary not null';
16 is compare($u3, $u0), 1, 'greater than binary';
17 }
18
19 {# string
20 my $u3 = uuid3(dns => 'www.example.com');
21 my $u0 = uuid0();
22 isnt $u3, $u0, 'string not null';
23 is compare($u3, $u0), 1, 'greater than string';
24 }
25
26 done_testing;