Search in sources :

Example 81 with IntegrationTestSpec

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

the class VariantRecalibratorIntegrationTest method testVariantRecalibratorIndel.

@Test
public void testVariantRecalibratorIndel() throws IOException {
    @SuppressWarnings("unused") final int hack = Utils.getRandomGenerator().nextInt();
    final String inputFile = getLargeVQSRTestDataDir() + "combined.phase1.chr20.raw.indels.filtered.sites.1M-10M.vcf";
    final IntegrationTestSpec spec = new IntegrationTestSpec(" --resource known,known=true,prior=10.0:" + getLargeVQSRTestDataDir() + "dbsnp_132_b37.leftAligned.20.1M-10M.vcf" + " --resource truth_training,training=true,truth=true,prior=15.0:" + getLargeVQSRTestDataDir() + "ALL.wgs.indels_mills_devine_hg19_leftAligned_collapsed_double_hit.sites.20.1M-10M.vcf" + " --variant " + inputFile + " -L 20:1,000,000-10,000,000" + " -an QD -an ReadPosRankSum -an HaplotypeScore" + " -mode INDEL -mG 3" + // for speed
    " --trustAllPolymorphic" + " --output %s" + " -tranchesFile %s" + " --addOutputVCFCommandLine false", Arrays.asList(// as input for the ApplyVQSR test
    getLargeVQSRTestDataDir() + "indelRecal.vcf", getLargeVQSRTestDataDir() + "expected/indelTranches.txt"));
    spec.executeTest("testVariantRecalibratorIndel" + inputFile, this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 82 with IntegrationTestSpec

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

the class VariantsToTableIntegrationTest method testMultiAllelicOneRecord.

@Test
public void testMultiAllelicOneRecord() throws IOException {
    final IntegrationTestSpec spec = new IntegrationTestSpec(variantsToTableMultiAllelicCmd(""), Arrays.asList(getToolTestDataDir() + "expected.multiallelic.table"));
    spec.executeTest("testMultiAllelicOneRecord", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 83 with IntegrationTestSpec

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

the class VariantsToTableIntegrationTest method testMoltenOutput.

@Test
public void testMoltenOutput() throws IOException {
    final IntegrationTestSpec spec = new IntegrationTestSpec(" --variant " + getToolTestDataDir() + "vcfexample2.vcf" + " -F CHROM -F POS -F ID -F REF -F ALT -F QUAL -F FILTER" + " --moltenize" + " -O %s", Arrays.asList(getToolTestDataDir() + "expected.vcfexample2.moltenize.table"));
    spec.executeTest("testMoltenOutput", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 84 with IntegrationTestSpec

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

the class ApplyVQSRIntegrationTest method testApplyRecalibrationAlleleSpecificINDELmode.

@Test
public void testApplyRecalibrationAlleleSpecificINDELmode() throws IOException {
    final String base = " -L 3:113005755-195507036" + " -mode INDEL -AS" + " -ts_filter_level 99.3" + " --variant " + getToolTestDataDir() + "VQSR.AStest.postSNPinput.vcf" + " --output %s" + " -tranchesFile " + getToolTestDataDir() + "VQSR.AStest.indels.tranches" + " -recalFile " + getToolTestDataDir() + "VQSR.AStest.indels.recal.vcf" + " --addOutputVCFCommandLine false";
    final IntegrationTestSpec spec = new IntegrationTestSpec(base, Arrays.asList(getToolTestDataDir() + "expected/applyIndelAlleleSpecificResult.vcf"));
    spec.executeTest("testApplyRecalibrationAlleleSpecificINDELmode", this);
}
Also used : IntegrationTestSpec(org.broadinstitute.hellbender.utils.test.IntegrationTestSpec) Test(org.testng.annotations.Test) CommandLineProgramTest(org.broadinstitute.hellbender.CommandLineProgramTest)

Example 85 with IntegrationTestSpec

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

the class FeatureSupportIntegrationTest method testFeatureSupportUsingVCF.

@Test
public void testFeatureSupportUsingVCF() throws IOException {
    IntegrationTestSpec testSpec = new IntegrationTestSpec(" -R " + hg19MiniReference + " -I " + FEATURE_INTEGRATION_TEST_DIRECTORY + "reads_data_source_test1.bam" + " -V " + "TestFeatures:" + FEATURE_INTEGRATION_TEST_DIRECTORY + "feature_data_source_test.vcf" + " --groupVariantsBySource" + " -O %s", Arrays.asList(FEATURE_INTEGRATION_TEST_DIRECTORY + "expected_testFeatureSupportUsingVCF_output.txt"));
    testSpec.executeTest("testFeatureSupportUsingVCF", 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