From 98c268483eb262150e4d54cdc0ef58d69437de19 Mon Sep 17 00:00:00 2001 From: hanna Date: Wed, 23 Dec 2009 23:12:22 +0000 Subject: [PATCH] Fixed issues with the integration tests: 1) sam-jdk apparently no longer supports custom tags with type int[] values. 2) BAM output for indel cleaner integration test changed in a way that's so subtle it can't be seen after converting the output to .sam. git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@2439 348d0f76-0448-11de-a6fe-93d51630548a --- .../sting/gatk/walkers/recalibration/RecalDataManager.java | 6 +++--- .../gatk/walkers/indels/IntervalCleanerIntegrationTest.java | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/java/src/org/broadinstitute/sting/gatk/walkers/recalibration/RecalDataManager.java b/java/src/org/broadinstitute/sting/gatk/walkers/recalibration/RecalDataManager.java index 3bb6ee3f2..cd2c74273 100644 --- a/java/src/org/broadinstitute/sting/gatk/walkers/recalibration/RecalDataManager.java +++ b/java/src/org/broadinstitute/sting/gatk/walkers/recalibration/RecalDataManager.java @@ -274,12 +274,12 @@ public class RecalDataManager { if( read.getReadNegativeStrandFlag() ) { readBases = BaseUtils.simpleReverseComplement( read.getReadBases() ); } - int[] inconsistency = new int[readBases.length]; + byte[] inconsistency = new byte[readBases.length]; int iii; byte prevBase = (byte) colorSpace[0]; // The sentinel for( iii = 0; iii < readBases.length; iii++ ) { byte thisBase = (byte)getNextBaseFromColor( (char)prevBase, colorSpace[iii + 1] ); - inconsistency[iii] = ( thisBase == readBases[iii] ? 0 : 1 ); + inconsistency[iii] = (byte)( thisBase == readBases[iii] ? 0 : 1 ); prevBase = readBases[iii]; } read.setAttribute( RecalDataManager.COLOR_SPACE_INCONSISTENCY_TAG, inconsistency ); @@ -469,7 +469,7 @@ public class RecalDataManager { */ public static boolean isInconsistentColorSpace( final SAMRecord read, final int offset ) { if( read.getAttribute(RecalDataManager.COLOR_SPACE_INCONSISTENCY_TAG) != null ) { - int[] colorSpace = ((int[])read.getAttribute(RecalDataManager.COLOR_SPACE_INCONSISTENCY_TAG)); + byte[] colorSpace = ((byte[])read.getAttribute(RecalDataManager.COLOR_SPACE_INCONSISTENCY_TAG)); return colorSpace[offset] != 0; } else { return false; diff --git a/java/test/org/broadinstitute/sting/gatk/walkers/indels/IntervalCleanerIntegrationTest.java b/java/test/org/broadinstitute/sting/gatk/walkers/indels/IntervalCleanerIntegrationTest.java index 08d1675fa..8d008d763 100755 --- a/java/test/org/broadinstitute/sting/gatk/walkers/indels/IntervalCleanerIntegrationTest.java +++ b/java/test/org/broadinstitute/sting/gatk/walkers/indels/IntervalCleanerIntegrationTest.java @@ -9,7 +9,7 @@ public class IntervalCleanerIntegrationTest extends WalkerTest { @Test public void testIntervals() { - String[] md5lod5 = {"042c1c2649a51a260bc204ec5f256c1a", "460631e8d98644dcf53b3045ca40f02a"}; + String[] md5lod5 = {"4a440cbb39a8093f28f6ce66d8b9a104", "460631e8d98644dcf53b3045ca40f02a"}; WalkerTestSpec spec1 = new WalkerTestSpec( "-T IntervalCleaner -LOD 5 -maxConsensuses 100 -greedy 100 -R /broad/1KG/reference/human_b36_both.fasta -I /humgen/gsa-scr1/GATK_Data/Validation_Data/NA12878.chrom1.SLX.SRP000032.2009_06.bam -L /humgen/gsa-scr1/GATK_Data/Validation_Data/cleaner.test.intervals --OutputCleaned %s -snps %s", 2,