Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
vidjil
vidjil
Commits
198c3d20
Commit
198c3d20
authored
May 15, 2019
by
Thonier Florian
Browse files
clone_test; update tests with the bug fix on 1based positions
link to
#3488
parent
09ec2c71
Changes
1
Hide whitespace changes
Inline
Side-by-side
browser/test/QUnit/testFiles/clone_test.js
View file @
198c3d20
...
...
@@ -15,7 +15,7 @@ QUnit.module("Clone", {
"
3start
"
:
15
,
"
5
"
:
{
'
start
'
:
1
,
'
end
'
:
5
},
// 0-based (old format, with 'end')
"
cdr3
"
:
{
"
start
"
:
11
,
"
start
"
:
8
,
"
stop
"
:
16
,
"
aa
"
:
"
ABCDE
"
},
...
...
@@ -248,10 +248,10 @@ QUnit.test("name, informations, getHtmlInfo", function(assert) {
"
getHtmlInfo: segmentation information (V gene) after changment
"
);
// Test junction in html export
assert
.
includes
(
html
,
"
<tr><td>junction</td><td colspan='4'>a
a
t</td></tr>
"
,
assert
.
includes
(
html
,
"
<tr><td>junction</td><td colspan='4'>a
t
t</td></tr>
"
,
"
getHtmlInfo c1: junction info for productive clone
"
);
html
=
c3
.
getHtmlInfo
();
assert
.
includes
(
html
,
"
<tr><td>junction</td><td colspan='4'>aaaaaaaa
a
ttt</td></tr>
"
,
assert
.
includes
(
html
,
"
<tr><td>junction</td><td colspan='4'>aaaaaaaa
t
ttt</td></tr>
"
,
"
getHtmlInfo c3: junction info for non productive clone
"
);
assert
.
includes
(
html
,
"
<tr><td>junction (AA seq)</td><td colspan='4'>WKIC</td></tr>
"
,
"
getHtmlInfo c3: junction (AAseq) info for non productive clone
"
);
...
...
@@ -272,10 +272,10 @@ QUnit.test('clone: get info from seg', function(assert) {
assert
.
notOk
(
c1
.
hasSeg
(
'
toto
'
),
"
clone1 doesn't have toto
"
)
assert
.
notOk
(
c1
.
hasSeg
(
'
junction
'
,
'
toto
'
),
"
clone1 has junction but doesn't have toto
"
)
assert
.
equal
(
c1
.
getSegLength
(
'
cdr3
'
),
6
,
"
CDR3 length
"
);
assert
.
equal
(
c1
.
getSegLength
(
'
cdr3
'
),
9
,
"
CDR3 length
"
);
assert
.
equal
(
c2
.
getSegLength
(
'
cdr3
'
),
'
undefined
'
,
"
no cdr3 in c2
"
);
var
pos_cdr3
=
c1
.
getSegStartStop
(
'
cdr3
'
)
assert
.
equal
(
pos_cdr3
[
'
start
'
],
10
,
"
CDR3 length
"
)
assert
.
equal
(
pos_cdr3
[
'
start
'
],
7
,
"
CDR3 length
"
)
assert
.
equal
(
pos_cdr3
[
'
stop
'
],
15
,
"
CDR3 length
"
)
assert
.
equal
(
c1
.
getSegStartStop
(
'
toto
'
),
null
,
"
no toto record
"
)
var
pos_junction
=
c3
.
getSegStartStop
(
'
junction
'
)
...
...
@@ -292,7 +292,8 @@ QUnit.test('clone: get info from seg', function(assert) {
c1
.
computeEValue
()
assert
.
equal
(
c1
.
eValue
,
1
e
-
2
,
'
Recomputing e-value should not change its value
'
)
assert
.
equal
(
c1
.
getSegNtSequence
(
'
junction
'
),
'
aat
'
,
'
junction c1
'
)
assert
.
equal
(
c1
.
getSegNtSequence
(
'
junction
'
),
'
att
'
,
'
junction c1
'
)
assert
.
equal
(
c1
.
getSegNtSequence
(
'
cdr3
'
),
'
aaatttttt
'
,
'
sequence cdr3 c1 (by getSegNtSequence)
'
)
assert
.
equal
(
c1
.
getSegAASequence
(
'
junction
'
),
''
,
'
no AA junction for c1
'
)
assert
.
equal
(
c1
.
getSegAASequence
(
'
cdr3
'
),
'
ABCDE
'
,
'
AA CDR3 for c1
'
)
...
...
@@ -439,7 +440,7 @@ QUnit.test("export", function(assert) {
"
TRG
"
,
"
-/-
"
,
"
undefined V
"
,
"
IGHD2*03
"
,
"
IGHV4*01
"
,
"
not productive
"
,
"
aaaaaaaa
a
ttt
"
,
"
aaaaaaaa
t
ttt
"
,
"
WKIC
"
,
"
AAAAAAAAAATTTTTTTTT
"
,
10
,
10
,
15
,
15
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment