Acme-Tools
view release on metacpan or search on metacpan
t/02_general.t view on Meta::CPAN
ok(dirname('/tmp/brbbbb.pl') eq '/tmp' ,'dirname');
ok(dirname('brbbbb.pl') eq '.' ,'dirname');
#--nicenum
# print 14.3 - 14.0; # 0.300000000000001
# print 34.3 - 34.0; # 0.299999999999997
#--fails sometimes, dunno why:
#http://www.cpantesters.org/cpan/report/fddd1d18-1b2c-11e7-9d0d-a625a53c07fe ( x 20, others also)
#my($inn,$n,$nn)=(0);
#my $nndebugstr=sub{++$inn;"nicenum$inn $n --> $Acme::Tools::Nicenum --> $nn"};
#$nn=nicenum( $n = 14.3 - 14.0 ); cmp_ok($nn,'==',0.3, &$nndebugstr);
#$nn=nicenum( $n = 34.3 - 34.0 ); cmp_ok($nn,'==',0.3, &$nndebugstr);
#$nn=nicenum( $n = 1e8+1 ); cmp_ok($nn,'==',1e8+1, &$nndebugstr);
( run in 0.374 second using v1.01-cache-2.11-cpan-3cd7ad12f66 )