File: date_misc_a.t

package info (click to toggle)
datemanip 5.33-1
  • links: PTS
  • area: main
  • in suites: slink
  • size: 480 kB
  • ctags: 87
  • sloc: perl: 6,461; makefile: 40; sh: 3
file content (34 lines) | stat: -rwxr-xr-x 585 bytes parent folder | download | duplicates (5)
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
#!/usr/local/bin/perl -w

require 5.001;
use Date::Manip;
@Date::Manip::TestArgs=();
$runtests=shift(@ARGV);
if ( -f "t/test.pl" ) {
  require "t/test.pl";
} elsif ( -f "test.pl" ) {
  require "test.pl";
} else {
  die "ERROR: cannot find test.pl\n";
}
$ntest=2;

print "1..$ntest\n"  if (! $runtests);
&Date_Init(@Date::Manip::TestArgs);

$dates="
# Tests YYMMDD time
1996061800:00:00
    19960618000000

# Tests YYMMDDHHMNSS
19960618000000
    19960618000000
";

print "Date (English,Internal=1)...\n";
&Date_Init("Internal=1");
&test_Func($ntest,\&ParseDate,$dates,$runtests);

1;