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
|
#!perl -w
use strict;
no strict "vars";
use Date::Pcalc qw( Compressed_to_Text );
# ======================================================================
# $datestr = Compressed_to_Text($date);
# ======================================================================
print "1..5\n";
$n = 1;
if (Compressed_to_Text(48163) eq "03-Jan-64") {print "ok $n\n";} else {print "not ok $n\n";}
$n++;
if (Compressed_to_Text( 0) eq "??-???-??") {print "ok $n\n";} else {print "not ok $n\n";}
$n++;
if (Compressed_to_Text(13170) eq "18-Nov-95") {print "ok $n\n";} else {print "not ok $n\n";}
$n++;
if (Compressed_to_Text(12892) eq "28-Feb-95") {print "ok $n\n";} else {print "not ok $n\n";}
$n++;
if (Compressed_to_Text(12893) eq "??-???-??") {print "ok $n\n";} else {print "not ok $n\n";}
__END__
|