File: helpers.t

package info (click to toggle)
libdata-perl-perl 0.002011-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 252 kB
  • sloc: perl: 364; makefile: 2
file content (38 lines) | stat: -rw-r--r-- 787 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
use Data::Perl;
use Test::More;


my $array = array(qw/1 2 3 4/);
isa_ok($array, 'Data::Perl::Collection::Array');

my $hash = hash(qw/1 2 3 4/);
isa_ok($hash, 'Data::Perl::Collection::Hash');

my $code = code();
isa_ok($code, 'Data::Perl::Code');

my $code2 = code(sub { 'foo' });
isa_ok($code2, 'Data::Perl::Code');

my $number = number();
isa_ok($number, 'Data::Perl::Number');

$number2 = number(2);
isa_ok($number2, 'Data::Perl::Number');

my $bool = bool(1);
isa_ok($bool, 'Data::Perl::Bool');

my $string = string();
isa_ok($string, 'Data::Perl::String');

my $string2 = string('foo');
isa_ok($string2, 'Data::Perl::String');

my $counter = counter();
isa_ok($counter, 'Data::Perl::Counter');

my $counter2 = counter(1);
isa_ok($counter2, 'Data::Perl::Counter');

done_testing();