Blame t/orig.datecalc.date_delta.1.t

Packit 95306a
#!/usr/bin/perl -w
Packit 95306a
Packit 95306a
use Test::Inter;
Packit 95306a
$t = new Test::Inter 'Orig :: DateCalc (date,delta,business 8:30-5:00)';
Packit 95306a
$testdir = '';
Packit 95306a
$testdir = $t->testdir();
Packit 95306a
Packit 95306a
use Date::Manip;
Packit 95306a
if (DateManipVersion() >= 6.00) {
Packit 95306a
   $t->feature("DM6",1);
Packit 95306a
}
Packit 95306a
Packit 95306a
$t->skip_all('Date::Manip 6.xx required','DM6');
Packit 95306a
Packit 95306a
Packit 95306a
sub test {
Packit 95306a
   my($d1,$d2) = (@_);
Packit 95306a
   DateCalc($d1,$d2);
Packit 95306a
}
Packit 95306a
Packit 95306a
Date_Init("ForceDate=1997-03-08-12:30:00,America/New_York");
Packit 95306a
Date_Init("ConfigFile=$testdir/Manip.cnf");
Packit 95306a
Date_Init("WorkDayBeg=08:30","WorkDayEnd=17:00");
Packit 95306a
Packit 95306a
$tests="
Packit 95306a
Packit 95306a
'Wed Nov 20 1996 noon' '+0:5:0:0 business' => 1996112108:30:00
Packit 95306a
Packit 95306a
'Wed Nov 20 1996 noon' '+3:7:0:0 business' => 1996112610:30:00
Packit 95306a
Packit 95306a
'Mar 31 1997 16:59:59' '+ 1 sec business'  => 1997040108:30:00
Packit 95306a
Packit 95306a
";
Packit 95306a
Packit 95306a
$t->tests(func  => \&test,
Packit 95306a
          tests => $tests);
Packit 95306a
$t->done_testing();
Packit 95306a
Packit 95306a
#Local Variables:
Packit 95306a
#mode: cperl
Packit 95306a
#indent-tabs-mode: nil
Packit 95306a
#cperl-indent-level: 3
Packit 95306a
#cperl-continued-statement-offset: 2
Packit 95306a
#cperl-continued-brace-offset: 0
Packit 95306a
#cperl-brace-offset: 0
Packit 95306a
#cperl-brace-imaginary-offset: 0
Packit 95306a
#cperl-label-offset: 0
Packit 95306a
#End: