ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/COMP/SCRAM/src/BuildSystem/test/test_Requirements.pm
Revision: 1.1.2.1.2.4
Committed: Thu Aug 24 09:50:06 2000 UTC (24 years, 8 months ago) by williamc
Content type: text/plain
Branch: HPWbranch
Changes since 1.1.2.1.2.3: +5 -7 lines
Log Message:
Change Requirements Interface

File Contents

# User Rev Content
1 williamc 1.1.2.1 #
2     # Requirements.pm test suite
3     #
4    
5     package BuildSystem::test::test_Requirements;
6     require 5.001;
7     use BuildSystem::Requirements;
8 williamc 1.1.2.1.2.4 use ActiveDoc::ActiveStore;
9 williamc 1.1.2.1
10     @ISA=qw(Utilities::TestClass); #methods both from the test class
11    
12     sub init {
13     my $self=shift;
14     $self->{testfile}=$self->datadir()."/RequirementsDocTest";
15    
16     # make a dummy toolbox
17     $self->{toolbox}=$self;
18 williamc 1.1.2.1.2.4 $self->{dbdir}=$self->temparea()."/RequirementsTest";
19     $self->{db}=ActiveDoc::ActiveStore->new($self->{dbdir});
20 williamc 1.1.2.1 }
21    
22     sub test {
23     my $self=shift;
24     $self->newtest("Initiation test");
25 williamc 1.1.2.1.2.4 $self->newobject($self->{db}, "file:".$self->{testfile});
26 williamc 1.1.2.1.2.1 $self->newtest("Download test");
27     $self->testinterface("download");
28    
29 williamc 1.1.2.1.2.3 $self->newtest("Selection test");
30     $self->expect("test","yetanothertool","toolb");
31     $self->testinterface("selectedtools");
32     $self->clearexpect();
33    
34     $self->newtest("Tool list test");
35     $self->expect("test","anothertest","yetanothertool","toola","toolb");
36     $self->testinterface("tools");
37     $self->clearexpect();
38    
39 williamc 1.1.2.1 $self->newtest("Setup Testing");
40     $self->testinterface("setup",$self);
41 williamc 1.1.2.1.2.3 $self->cmparray($self->{toolsetups},"test","yetanothertool","toolb");
42 williamc 1.1.2.1.2.1
43     $self->newtest("URL Test");
44     $self->expect("cvs://cmscvs.cern.ch/cvs_server/repositories/SCRAM?auth=pserver&module=test/testtool&passkey=AA_:yZZ3e&user=anonymous&version=A");
45 williamc 1.1.2.1.2.4 $self->testinterface("toolurl","test");
46 williamc 1.1.2.1.2.1 $self->clearexpect();
47 williamc 1.1.2.1 }
48    
49     # --- stubs
50     sub toolsetup {
51     my $self=shift;
52     push @{$self->{toolsetups}}, shift;
53     }