Commit 8953a108 authored by Mathieu Giraud's avatar Mathieu Giraud

QUnit: streamline clone and sample names

parent a27c8bf6
......@@ -65,7 +65,7 @@ test("clone : name", function() {
equal(c1.getSequenceReads(), 10, "clone c1 reads : 10");
equal(c1.getSequenceSize(), "0.05", "clone c1 size : 0.05");
console.log(m.samples.order)
equal(c1.getHtmlInfo(), "<h2>Cluster info : hello</h2><div id='info_window'><table><tr><th></th><td>Leu+0_BCD</td><td>Leu+1_BCD</td><td>Leu+2_BCD</td><td>Leu+3_BCD</td></tr><tr><td class='header' colspan='5'> clone information </td></tr><tr><td> clone name </td><td colspan='4'>hello</td></tr><tr><td> clone size (n-reads (total reads) )</td><td>20 (200)</td><td>20 (100)</td><td>30 (200)</td><td>30 (100)</td></tr><tr><td> clone size (%)</td><td>10.000 % </td><td>20.000 % </td><td>15.000 % </td><td>30.000 % </td><tr><td class='header' colspan='5'> cluster's main sequence information</td></tr><tr><td> sequence name </td><td colspan='4'>hello</td></tr><tr><td> code </td><td colspan='4'>hello</td></tr><tr><td> size (n-reads (total reads) )</td><td>10 (200)</td><td>10 (100)</td><td>15 (200)</td><td>15 (100)</td></tr><tr><td> size (%)</td><td>5.000 % </td><td>10.000 % </td><td>7.500 % </td><td>15.000 % </td></tr><tr><td class='header' colspan='5'> segmentation information</td></tr><tr><td> sequence </td><td colspan='4'>abcdefghijklmnopqrstuvwxyz</td></tr><tr><td> id </td><td colspan='4'>id1</td></tr><tr><td> 5 </td><td colspan='4'>undefined V</td></tr><tr><td> 4 </td><td colspan='4'>IGHD2*03</td></tr><tr><td> 3 </td><td colspan='4'>IGHV4*01</td></tr><tr><td class='header' colspan='5'> other information</td></tr></table></div>",
equal(c1.getHtmlInfo(), "<h2>Cluster info : hello</h2><div id='info_window'><table><tr><th></th><td>Diag</td><td>Fu-1</td><td>Fu-2</td><td>Fu-3</td></tr><tr><td class='header' colspan='5'> clone information </td></tr><tr><td> clone name </td><td colspan='4'>hello</td></tr><tr><td> clone size (n-reads (total reads) )</td><td>20 (200)</td><td>20 (100)</td><td>30 (200)</td><td>30 (100)</td></tr><tr><td> clone size (%)</td><td>10.000 % </td><td>20.000 % </td><td>15.000 % </td><td>30.000 % </td><tr><td class='header' colspan='5'> cluster's main sequence information</td></tr><tr><td> sequence name </td><td colspan='4'>hello</td></tr><tr><td> code </td><td colspan='4'>hello</td></tr><tr><td> size (n-reads (total reads) )</td><td>10 (200)</td><td>10 (100)</td><td>15 (200)</td><td>15 (100)</td></tr><tr><td> size (%)</td><td>5.000 % </td><td>10.000 % </td><td>7.500 % </td><td>15.000 % </td></tr><tr><td class='header' colspan='5'> segmentation information</td></tr><tr><td> sequence </td><td colspan='4'>abcdefghijklmnopqrstuvwxyz</td></tr><tr><td> id </td><td colspan='4'>id1</td></tr><tr><td> 5 </td><td colspan='4'>undefined V</td></tr><tr><td> 4 </td><td colspan='4'>IGHD2*03</td></tr><tr><td> 3 </td><td colspan='4'>IGHV4*01</td></tr><tr><td class='header' colspan='5'> other information</td></tr></table></div>",
"getHtmlInfo");
......
......@@ -11,17 +11,17 @@ json_data = {
"samples": {
"timestamp": ["2014-10-20 13:59:02", "2014-10-25 14:00:32", "2014-11-20 14:03:13", "2014-12-20 14:04:48"],
"commandline": [
"./vidjil -c clones -g germline/ -r 1 -o ./out0 -z 200 -n 5 Leu+0_BCD.cut.fa ",
"./vidjil -c clones -g germline/ -r 1 -o ./out1 -z 200 -n 5 Leu+1_BCD.cut.fa ",
"./vidjil -c clones -g germline/ -r 1 -o ./out2 -z 200 -n 5 Leu+2_BCD.cut.fa ",
"./vidjil -c clones -g germline/ -r 1 -o ./out3 -z 200 -n 5 Leu+3_BCD.cut.fa "
"./vidjil -c clones -g germline/ -r 1 -o ./out0 -z 200 -n 5 Diag.fa ",
"./vidjil -c clones -g germline/ -r 1 -o ./out1 -z 200 -n 5 Fu-1.fa ",
"./vidjil -c clones -g germline/ -r 1 -o ./out2 -z 200 -n 5 Fu-2.fa ",
"./vidjil -c clones -g germline/ -r 1 -o ./out3 -z 200 -n 5 Fu-3.fa "
],
"number": 4,
"original_names": [
"Leu+0_BCD.cut.fa",
"Leu+1_BCD.cut.fa",
"Leu+2_BCD.cut.fa",
"Leu+3_BCD.cut.fa"
"Diag.fa",
"Fu-1.fa",
"Fu-2.fa",
"Fu-3.fa"
],
"log": [
" ==> segmented 362296 reads (38.7%)\n ==> found 11526 40-windows in 335725 segments (35.8%) inside 937164 sequences\n ",
......@@ -38,7 +38,7 @@ json_data = {
{
"sequence" : "aaaaaaaaaaaaaaaaaaaaa",
"name" : "test1",
"id" : "riri",
"id" : "id1",
"reads" : [10,10,15,15] ,
"top" : 1,
"germline" : "TRG",
......@@ -52,7 +52,7 @@ json_data = {
{
"sequence" : "bbbbbbbbbbbbbbb",
"name" : "test2",
"id" : "fifi",
"id" : "id2",
"reads" : [20,20,10,10] ,
"top" : 2,
"germline" : "TRG",
......@@ -66,7 +66,7 @@ json_data = {
{
"sequence" : "cccccccccccccccccccc",
"name" : "test3",
"id" : "loulou",
"id" : "id3",
"reads" : [25,25,50,50] ,
"top" : 3,
"germline" : "IGH",
......
......@@ -30,7 +30,7 @@ test("model : time control", function() {
m.changeTimeOrder([0,1,2,3])
equal(m.getStrTime(0, "sampling_date"), "2014-10-20", "get sampling date")
equal(m.getStrTime(0, "name"), "Leu+0_BCD", "get time original name")
equal(m.getStrTime(0, "name"), "Diag", "get time original name")
equal(m.dateDiffInDays("2014-10-05", "2014-10-10"), "+5", "datediffindays")
equal(m.getStrTime(1, "delta_date"), "+5", "get day since diag")
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment