2
## Bioperl Test Harness Script for Modules
3
## $Id: LinkageMap.t,v 1.2 2005/09/16 12:22:36 bosborne Exp $
10
$DEBUG = $ENV{'BIOPERLDEBUG'};
11
# to handle systems with no installed Test module
12
# we include the t dir (where a copy of Test.pm is located)
14
eval { require Test; };
27
use Bio::Map::LinkagePosition;
28
use Bio::Map::Microsatellite;
29
use Bio::Map::LinkageMap;
33
ok my $map = new Bio::Map::LinkageMap('-verbose' => $verbose,
34
'-name' => 'Leviathon',
37
'-species' => "Brassica");
38
ok ref($map), 'Bio::Map::LinkageMap';
39
ok $map->name, 'Leviathon';
40
ok $map->type, 'Genetic';
42
ok $map->species, 'Brassica';
43
ok $map->unique_id, '1';
45
ok my $position = new Bio::Map::LinkagePosition('-order' => 2,
50
ok $position->order, 2;
51
ok $position->map, $map,
52
ok $position->value, 22.3;
54
ok my $o_usat = new Bio::Map::Microsatellite('-name' => "Chad marker",
55
'-position' => $position);
57
ok $o_usat->name, 'Chad marker';
58
ok $o_usat->position, $position ;
59
ok $map->add_element($o_usat);
61
#use Data::Dumper; print Dumper($map);
62
#----------------------------
63
#ok my $position2 = new Bio::Map::LinkagePosition(-order => qw(3 4 5),
65
# print("position2 looks like this:\n");
66
# dumpValue($position2);
67
#ok(($position2->each_position_value('fakemap'))[0] == 0);
68
#ok $position2->order, 3;
71
#ok($position->order, 2);
72
#ok(($position->each_position_value($map))[0], 22.3);
73
# what should be printed if this was ok?
76
#ok my $o_usat = new Bio::Map::Microsatellite('-name' => "Chad marker",
77
# '-position' => $position);
79
#ok $o_usat->name, 'Chad marker';
80
#ok $o_usat->position, $position ;
81
#ok $map->add_element($o_usat);
82
# what should be printed if this is ok?
86
# see also t/microsatellite.t and t/linkageposition.t