File: settime.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 (49 lines) | stat: -rwxr-xr-x 663 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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
#!/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=5;

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

$tests="

Jan 1, 1996  at 10:30
12:40
   1996010112:40:00

1996010110:30:40
12:40:50
   1996010112:40:50

1996010110:30:40
12:40
   1996010112:40:00

1996010110:30:40
12
40
   1996010112:40:00

1996010110:30:40
12
40
50
   1996010112:40:50

";

print "SetTime...\n";
&test_Func($ntest,\&Date_SetTime,$tests,$runtests);

1;