Search in sources :

Example 51 with IntegrationTestSpec

use of org.broadinstitute.hellbender.utils.test.IntegrationTestSpec in project gatk by broadinstitute.

the class ValidateVariantsIntegrationTest method testBadID2_OKif_notInDBSNP.

@Test
public void testBadID2_OKif_notInDBSNP() throws IOException {
    final IntegrationTestSpec spec = new IntegrationTestSpec(baseTestString(false, "validationExampleRSIDonPositionNotInDBSNP.vcf", false, IDS) + " --dbsnp " + hg19_chr1_1M_dbSNP_modified, Collections.emptyList());
    spec.executeTest("test bad RS ID is OK when not in dbSNP even with dbsnp arg", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 52 with IntegrationTestSpec

use of org.broadinstitute.hellbender.utils.test.IntegrationTestSpec in project gatk by broadinstitute.

the class ValidateVariantsIntegrationTest method testBadRefBase1.

@Test
public void testBadRefBase1() throws IOException {
    IntegrationTestSpec spec = new IntegrationTestSpec(baseTestString(false, "validationExampleBad.vcf", false, REF), 0, UserException.FailsStrictValidation.class);
    spec.executeTest("test bad ref base #1", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) UserException(org.broadinstitute.hellbender.exceptions.UserException) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 53 with IntegrationTestSpec

use of org.broadinstitute.hellbender.utils.test.IntegrationTestSpec in project gatk by broadinstitute.

the class SplitNCigarReadsIntegrationTest method testSplitsWithOverhangs.

@Test
public void testSplitsWithOverhangs() throws Exception {
    IntegrationTestSpec spec = new IntegrationTestSpec("-R " + b37_reference_20_21 + " -I " + largeFileTestDir + "NA12878.RNAseq.bam -O %s --processSecondaryAlignments", Arrays.asList(largeFileTestDir + "expected.NA12878.RNAseq.splitNcigarReads.bam"));
    spec.executeTest("test splits with overhangs", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 54 with IntegrationTestSpec

use of org.broadinstitute.hellbender.utils.test.IntegrationTestSpec in project gatk by broadinstitute.

the class CheckPileupIntegrationTest method testBAQPileup.

/**
     * This test runs on a basic pileup obtained with samtools (version 1.3.1) and options --min-BQ 0
     * BAQ quality recalibration is activated and should be different
     */
@Test
public void testBAQPileup() throws IOException {
    // pileup was generated with "samtools -f hg19MiniReference --min-BQ 0 reads_data_source_test1.bam"
    IntegrationTestSpec testSpec = new IntegrationTestSpec(" --continue_after_error " + " -R " + hg19MiniReference + " -I " + TEST_DATA_DIRECTORY + "reads_data_source_test1.bam" + " -pileup " + TEST_OUTPUT_DIRECTORY + "reads_data_source_test1.samtools.baq.pileup" + " -O %s", Arrays.asList(TEST_OUTPUT_DIRECTORY + "reads_data_source_test1.samtools.baq.pileup.diff"));
    testSpec.executeTest("testBasicPileup", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 55 with IntegrationTestSpec

use of org.broadinstitute.hellbender.utils.test.IntegrationTestSpec in project gatk by broadinstitute.

the class PileupIntegrationTest method testFeaturesPileup.

@Test
public void testFeaturesPileup() throws IOException {
    // GATK 3.5 code have a the last line with a REDUCE RESULT that was removed in this implementation
    // GATK 3.5 code have ROD instead of Feature(s) and the source of a VariantContext is set to metadata, thus the output was modified with the following command
    // awk '{gsub("metadata", "Unknown", $0); gsub("\\[ROD: ", "\[Feature(s): ", $0); print $0}'
    IntegrationTestSpec testSpec = new IntegrationTestSpec(" -L 20:10000092-10000112" + " -R " + b37_reference_20_21 + " -I " + NA12878_20_21_WGS_bam + " -metadata " + dbsnp_138_b37_20_21_vcf + " -O %s", Arrays.asList(TEST_OUTPUT_DIRECTORY + "expectedFeaturesPileup.txt"));
    testSpec.executeTest("testFeaturesPileup", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Aggregations

IntegrationTestSpec (org.broadinstitute.hellbender.utils.test.IntegrationTestSpec)201 CommandLineProgramTest (org.broadinstitute.hellbender.CommandLineProgramTest)200 Test (org.testng.annotations.Test)200 BaseTest (org.broadinstitute.hellbender.utils.test.BaseTest)80 UserException (org.broadinstitute.hellbender.exceptions.UserException)25 ArgumentsBuilder (org.broadinstitute.hellbender.utils.test.ArgumentsBuilder)14 File (java.io.File)10 Configuration (org.apache.hadoop.conf.Configuration)2 org.apache.hadoop.fs (org.apache.hadoop.fs)2 MiniDFSCluster (org.apache.hadoop.hdfs.MiniDFSCluster)2 SimpleInterval (org.broadinstitute.hellbender.utils.SimpleInterval)2 Path (org.apache.hadoop.fs.Path)1