Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
ensembl
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
1
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ensembl-gh-mirror
ensembl
Commits
1fe9d658
Commit
1fe9d658
authored
22 years ago
by
Arne Stabenau
Browse files
Options
Downloads
Patches
Plain Diff
some cleanup
parent
1ce9e375
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/t/mapper.t
+9
-13
9 additions, 13 deletions
modules/t/mapper.t
with
9 additions
and
13 deletions
modules/t/mapper.t
+
9
−
13
View file @
1fe9d658
...
@@ -23,7 +23,9 @@
...
@@ -23,7 +23,9 @@
# This test script heavily edited by ihh@fruitfly.org
# This test script heavily edited by ihh@fruitfly.org
## We start with some black magic to print on failure.
## We start with some black magic to print on failure.
BEGIN
{
$|
=
1
;
print
"
1..5
\n
";
# 5 tests total
BEGIN
{
$|
=
1
;
use
Test
;
plan
tests
=>
5
;
# 5 tests total
use
vars
qw($loaded)
;
}
use
vars
qw($loaded)
;
}
END
{
print
"
not ok 1
\n
"
unless
$loaded
;
}
END
{
print
"
not ok 1
\n
"
unless
$loaded
;
}
...
@@ -31,17 +33,16 @@ use lib 't';
...
@@ -31,17 +33,16 @@ use lib 't';
$loaded
=
1
;
$loaded
=
1
;
# $n_test = 0;
# $n_test = 0;
print
ok
();
ok
(
1
);
use
Bio::EnsEMBL::
Mapper
;
use
Bio::EnsEMBL::
Mapper
;
# testing the Bio::EnsEMBL::Mapper module
$mapper
=
Bio::EnsEMBL::
Mapper
->
new
(
"
rawcontig
",
"
virtualcontig
"
);
$mapper
=
Bio::EnsEMBL::
Mapper
->
new
(
"
rawcontig
",
"
virtualcontig
"
);
load_sgp_dump
(
$mapper
,
undef
);
load_sgp_dump
(
$mapper
,
undef
);
# loading done successfully
# loading done successfully
print
ok
();
ok
(
1
);
# transform a segment entirely within the first rawcontig
# transform a segment entirely within the first rawcontig
test_transform
(
$mapper
,
test_transform
(
$mapper
,
...
@@ -88,7 +89,7 @@ sub test_transform {
...
@@ -88,7 +89,7 @@ sub test_transform {
warn
"
Dest:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@coord
);
warn
"
Dest:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@coord
);
warn
"
Expected:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@dest
);
warn
"
Expected:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@dest
);
warn
"
Wrong number of segments
\n
";
warn
"
Wrong number of segments
\n
";
printnot
ok
();
ok
(
0
);
return
;
return
;
}
}
for
(
my
$i
=
0
;
$i
<
@coord
;
++
$i
)
{
for
(
my
$i
=
0
;
$i
<
@coord
;
++
$i
)
{
...
@@ -100,12 +101,12 @@ sub test_transform {
...
@@ -100,12 +101,12 @@ sub test_transform {
warn
"
Dest:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@coord
);
warn
"
Dest:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@coord
);
warn
"
Expected:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@dest
);
warn
"
Expected:
\n
",
map
("
(
"
.
join
("
,
",
@
$_
)
.
"
)
\n
",
@dest
);
warn
"
Error in segment
",
$i
+
1
,
"
field
",
$n
+
1
,
"
\n
";
warn
"
Error in segment
",
$i
+
1
,
"
field
",
$n
+
1
,
"
\n
";
printnot
ok
();
ok
(
0
);
return
;
return
;
}
}
}
}
}
}
print
ok
();
ok
(
1
);
return
;
return
;
}
}
...
@@ -243,9 +244,4 @@ chr1 625359 1214016 1216330 1 2315 1
...
@@ -243,9 +244,4 @@ chr1 625359 1214016 1216330 1 2315 1
#
#
sub
isgap
{
my
(
$obj
)
=
@_
;
return
!
$obj
->
can
('
strand
')
}
sub
isgap
{
my
(
$obj
)
=
@_
;
return
!
$obj
->
can
('
strand
')
}
# ok & notok subroutines
sub
printok
{
print
"
ok
\n
"
}
sub
printnotok
{
print
"
not ok
\n
"
}
#sub printok { print "ok ", ++$n_test, "\n" }
#sub printnotok { print "not ok ", ++$n_test, "\n" }
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment