Skip to content

Commit

Permalink
Fixing up tests in MarkDuplicates so that tests with duplex UMIs are …
Browse files Browse the repository at this point in the history
…handled properly (#1404)

* Fixing up tests in MarkDuplicates so that tests with duplex UMIs are handled properly.
  • Loading branch information
fleharty authored Sep 30, 2019
1 parent 34d7285 commit ab140e2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,22 @@ private class MarkDuplicatesWithMissingBarcodesTester extends MarkDuplicatesTest
@Override
public void runTest() {
boolean hasRX = false;
boolean isDuplex = false;
for (final String argument : this.getArgs()) {
if (argument.startsWith(getArgumentName())) {
hasRX = true;
break;
}
if (argument.startsWith("DUPLEX_UMI")) {
isDuplex = true;
break;
}
}

// Tests that specify the RX tag, or the DUPLEX_UMI argument should not be used with missing barcodes.
if (!hasRX && !isDuplex) {
addArg(getArgumentName() + "=" + getTagValue());
}
if (!hasRX) addArg(getArgumentName() + "=" + getTagValue());

super.runTest();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ public void testWithIndividualReadBarcodes() {
}

@DataProvider(name = "testDuplexUmiDataProvider")
private Object[][] testDuplexUmiDataProvider() {
public Object[][] testDuplexUmiDataProvider() {
return new Object[][]{
{
// Test case where UMIs are not duplex, but are the same.
Expand Down Expand Up @@ -358,7 +358,7 @@ private Object[][] testDuplexUmiDataProvider() {
};
}

@Test(dataProvider = "testDuplexUmiDataProvider",enabled = false)
@Test(dataProvider = "testDuplexUmiDataProvider")
public void testWithUMIs(final boolean duplexUmi, final List<String> UMIs, final List<Integer> alignmentStart1,
final List<Integer> alignmentStart2, final List<Boolean> isDuplicate,
final List<Boolean> isFirstNegativeStrand, final List<Boolean> isSecondNegativeStrand) {
Expand Down

0 comments on commit ab140e2

Please sign in to comment.