private int TEST_GRP_HEIGHT = 0;
+ private int TEST_ANOT_HEIGHT = 0;
+
@Before
public void setUp() throws Exception
{
// Alignment al = new Alignment(seqs);
TEST_SEQ_HEIGHT = jsonFile.seqs.size();
TEST_GRP_HEIGHT = jsonFile.seqGroups.size();
+ TEST_ANOT_HEIGHT = jsonFile.annotations.size();
}
@After
++matchedCounter;
}
}
- Assert.assertTrue(matchedCounter == TEST_GRP_HEIGHT);
}
+ Assert.assertTrue(matchedCounter == TEST_GRP_HEIGHT);
+
+ matchedCounter = 0;
+ for (AlignmentAnnotation in : jsonFile.annotations)
+ {
+ for (AlignmentAnnotation out : output.annotations)
+ {
+ try
+ {
+ // System.out.println("label >>>>> " + in.label + " | " + out.label);
+ // System.out.println("label >>>>> " + in.description + " | "
+ // + out.description);
+ // System.out.println("label >>>>> " + in.annotations.length + " | "
+ // + out.annotations.length);
+ if (in.label.equals(out.label)
+ && in.description.equals(out.description)
+ && in.annotations.length == out.annotations.length)
+ {
+ ++matchedCounter;
+ }
+ } catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ }
+ }
+ // System.out.println("matched >>>>> " + matchedCounter + " | "
+ // + TEST_ANOT_HEIGHT);
+ Assert.assertTrue(matchedCounter == TEST_ANOT_HEIGHT);
}