Attention une mise à jour du serveur va être effectuée le lundi 17 mai entre 13h et 13h30. Cette mise à jour va générer une interruption du service de quelques minutes.

Commit b2dfe766 authored by Mathieu Giraud's avatar Mathieu Giraud

tests: update, no more 'delta_min'

Mostly calls to Germline() constructors.
See #1674.
parent b22be0a9
......@@ -7,13 +7,13 @@
using namespace std;
void testSegmentationBug1(IndexTypes index, int delta_min) {
void testSegmentationBug1(IndexTypes index) {
string buggy_sequences = "bugs/kmersegment.fa";
BioReader seqV("../../germline/homo-sapiens/TRGV.fa");
BioReader seqJ("../../germline/homo-sapiens/TRGJ.fa");
Germline *germline ;
germline = new Germline("custom", 'x', seqV, seqV, seqJ, delta_min, "#############");
germline = new Germline("custom", 'x', seqV, seqV, seqJ, "#############");
germline->new_index(index);
germline->finish();
......@@ -54,6 +54,6 @@ void testSegmentationBug1(IndexTypes index, int delta_min) {
}
void testBugs() {
testSegmentationBug1(KMER_INDEX, -10);
testSegmentationBug1(AC_AUTOMATON, -10);
testSegmentationBug1(KMER_INDEX);
testSegmentationBug1(AC_AUTOMATON);
}
......@@ -53,7 +53,7 @@ void testFineSegment(IndexTypes index)
data.next();
Germline *germline ;
germline = new Germline("IGH", 'G', seqV, seqD, seqJ, 0, "########");
germline = new Germline("IGH", 'G', seqV, seqD, seqJ, "########");
germline->new_index(index);
germline->finish();
......@@ -105,11 +105,11 @@ void testSegmentOverlap(IndexTypes index)
BioReader data("../../data/bug-segment-overlap.fa", 1, " ");
Germline *germline1 ;
germline1 = new Germline("TRG", 'G', seqV, BioReader(), seqJ, -50, "##########");
germline1 = new Germline("TRG", 'G', seqV, BioReader(), seqJ, "##########");
germline1->new_index(index);
Germline *germline2 ;
germline2 = new Germline("TRG2", 'G', seqV, BioReader(), seqJ, -50, "##########");
germline2 = new Germline("TRG2", 'G', seqV, BioReader(), seqJ, "##########");
germline2->new_index(index);
germline1->finish();
......@@ -141,7 +141,7 @@ void testSegmentationCause(IndexTypes index) {
BioReader data("../../data/segmentation.fasta", 1, " ");
Germline *germline ;
germline = new Germline("TRG", 'G', seqV, BioReader(), seqJ, 0, "##########");
germline = new Germline("TRG", 'G', seqV, BioReader(), seqJ, "##########");
germline->new_index(index);
germline->finish();
......@@ -267,7 +267,7 @@ void testBug2224(IndexTypes index) {
Germline *germline ;
germline = new Germline("TRG", 'G', seqV, BioReader(), seqJ, 0, "###########");
germline = new Germline("TRG", 'G', seqV, BioReader(), seqJ, "###########");
germline->new_index(index);
germline->finish();
......@@ -289,7 +289,7 @@ void testExtractor(IndexTypes index) {
OnlineFasta data("../../data/segmentation.fasta", 1, " ");
Germline *germline ;
germline = new Germline("TRG", 'G', seqV, BioReader(), seqJ, 0, "##########");
germline = new Germline("TRG", 'G', seqV, BioReader(), seqJ, "##########");
germline->new_index(index);
MultiGermline *multi ;
......@@ -372,7 +372,7 @@ void testProbability(IndexTypes index) {
V.add(v);
J.add(j);
}
Germline germline("Test", 'T', V, BioReader(), J, 0, "####");
Germline germline("Test", 'T', V, BioReader(), J, "####");
germline.new_index(index);
germline.finish();
......
......@@ -7,7 +7,7 @@ void testWSAdd() {
map<string, string> labels;
WindowsStorage ws(labels);
Sequence seq = {"label", "l", "GATACATTAGACAGCT", "", NULL, 0};
Germline germline("Test", 't', "../../data/small_V.fa", "", "../../data/small_J.fa", -10, "");
Germline germline("Test", 't', "../../data/small_V.fa", "", "../../data/small_J.fa", "");
TAP_TEST(ws.size() == 0, TEST_WS_SIZE_NONE, "");
......@@ -49,7 +49,7 @@ void testWSAdd() {
TAP_TEST(it->label_full == "other", TEST_WS_GET_READS, "");
TAP_TEST(it->sequence == "TAAGATTAGCCACGGACT", TEST_WS_GET_READS, "");
Germline germline2("Other test", 'o', "../../data/small_V.fa", "", "../../data/small_J.fa", -20, "");
Germline germline2("Other test", 'o', "../../data/small_V.fa", "", "../../data/small_J.fa", "");
// Insert a sequence from another germline 2 times
for (int i = 0; i < 2; i++) {
ws.add("CATT", seq, SEG_MINUS, &germline2);
......@@ -59,7 +59,7 @@ void testWSAdd() {
TAP_TEST(ws.getGermline("ATTAG") == &germline,TEST_WS_GET_GERMLINE, "");
TAP_TEST(ws.getGermline("CATT") == &germline2,TEST_WS_GET_GERMLINE, "");
Germline germline3("Another test", 'a', "../../data/small_V.fa", "", "../../data/small_J.fa", -52, "");
Germline germline3("Another test", 'a', "../../data/small_V.fa", "", "../../data/small_J.fa", "");
// Insert a sequence from another germline 6 times
for (int i = 0; i < 6; i++) {
ws.add("ATAGCAT", seq, SEG_MINUS, &germline3);
......@@ -114,7 +114,7 @@ void testWSAddWithLimit() {
ws.setBinParameters(1, 20);
Sequence seq = {"label", "l", "GATACATTAGACAGCT", "", NULL, 0};
Sequence seq_long = {"label", "l", "GATACATTAGACAGCTTATATATATATTTATAT", "", NULL, 0};
Germline germline("Test", 't', "../../data/small_V.fa", "", "../../data/small_J.fa", -10, "");
Germline germline("Test", 't', "../../data/small_V.fa", "", "../../data/small_J.fa", "");
ws.add("ATTAG", seq, SEG_PLUS, &germline);
ws.add("ATTAG", seq, SEG_PLUS, &germline);
......
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