Assert.assertEquals(tool.interpret(m, smallInterval), QualifyMissingIntervals.Interpretation.SMALL_INTERVAL.toString());
}
@Test(enabled = true)
void testGetPositionInTarget () {
final UnvalidatingGenomeLoc target = new UnvalidatingGenomeLoc("a", 0, 30, 50);
final List<GenomeLoc> targets = new ObjectArrayList<>(1);
targets.add(target);
// left overlap
UnvalidatingGenomeLoc interval = new UnvalidatingGenomeLoc("a", 0, 10, 50);
Assert.assertEquals(QualifyMissingIntervals.getPositionInTarget(interval, targets), -20);
// right overlap
interval = new UnvalidatingGenomeLoc("a", 0, 40, 60);
Assert.assertEquals(QualifyMissingIntervals.getPositionInTarget(interval, targets), -10);
// interval > target with short right tail
interval = new UnvalidatingGenomeLoc("a", 0, 10, 60);
Assert.assertEquals(QualifyMissingIntervals.getPositionInTarget(interval, targets), -10);
// interval > target with short left tail
interval = new UnvalidatingGenomeLoc("a", 0, 10, 80);
Assert.assertEquals(QualifyMissingIntervals.getPositionInTarget(interval, targets), -30);
// interval < target with short right tail
interval = new UnvalidatingGenomeLoc("a", 0, 32, 40);
Assert.assertEquals(QualifyMissingIntervals.getPositionInTarget(interval, targets), 2);
// interval < target with short left tail
interval = new UnvalidatingGenomeLoc("a", 0, 40, 42);
Assert.assertEquals(QualifyMissingIntervals.getPositionInTarget(interval, targets), 8);
// no overlap
interval = new UnvalidatingGenomeLoc("a", 0, 40, 42);
Assert.assertEquals(QualifyMissingIntervals.getPositionInTarget(interval, new ObjectArrayList<GenomeLoc>()), Integer.MIN_VALUE);
}