Last change
on this file since 169 was
169,
checked in by thauvin, 19 years ago
|
- enforce test with use strict, warnings
|
-
Property cvs2svn:cvs-rev set to
1.2
-
Property svn:keywords set to
Author Date Id Revision
-
Property svn:mime-type set to
text/x-troff
|
File size:
1003 bytes
|
Line | |
---|
1 | # $Id$ |
---|
2 | |
---|
3 | use strict; |
---|
4 | use warnings; |
---|
5 | |
---|
6 | use Test::More tests => 8; |
---|
7 | use File::Temp qw(tempdir); |
---|
8 | |
---|
9 | use_ok('ObsData'); |
---|
10 | use_ok('ObsData::Repository'); |
---|
11 | |
---|
12 | my $o = ObsData->new( |
---|
13 | 'testdata/obsdata-conftest', |
---|
14 | logfile => "testdata/obsdata.log", |
---|
15 | verbose => 0, |
---|
16 | ); |
---|
17 | $o->load(); |
---|
18 | |
---|
19 | { |
---|
20 | my $or = ObsData::Repository::dir::archive->new( |
---|
21 | { |
---|
22 | obsdata => $o, |
---|
23 | dir => 'testdata/ohp', |
---|
24 | archivefile => 'ozone34.gz', |
---|
25 | statusfile => 'testdata/test-index.ini', |
---|
26 | dry_run => 1, |
---|
27 | } |
---|
28 | ); |
---|
29 | isa_ok($or, "ObsData::Repository::dir::archive"); |
---|
30 | ok($or->do_check('archive_exists'), "can perform check archive_exists"); |
---|
31 | ok(!$or->do_check('archive_size'), "can perform check archive_size"); |
---|
32 | ok(!$or->do_check('archive_mtime'), "can perform check archive_mtime"); |
---|
33 | ok($or->do_check('dest_exists', 'ozone34', '34/ozone34'), "can perform check dest_exists"); |
---|
34 | ok($or->do_check('data_extracted', 'ozone34'), "can perform check data_extracted"); |
---|
35 | } |
---|
36 | |
---|
Note: See
TracBrowser
for help on using the repository browser.