Search in sources :

Example 61 with BeforeClass

use of org.testng.annotations.BeforeClass in project gatk-protected by broadinstitute.

the class TargetCoverageSexGenotypeCalculatorUnitTest method initSexGenotyper.

@BeforeClass
public static void initSexGenotyper() {
    final List<ContigGermlinePloidyAnnotation> contigPloidyAnnotsList;
    final ReadCountCollection readCounts;
    try {
        contigPloidyAnnotsList = ContigGermlinePloidyAnnotationTableReader.readContigGermlinePloidyAnnotationsFromFile(TEST_CONTIG_PLOIDY_ANNOTS_FILE);
        readCounts = ReadCountCollectionUtils.parse(TEST_RCC_FILE);
    } catch (final IOException ex) {
        throw new UserException.CouldNotReadInputFile("Could not read test resource files");
    }
    genotyper = new TargetCoverageSexGenotypeCalculator(readCounts, readCounts.targets(), contigPloidyAnnotsList, DEFAULT_MAPPING_ERROR_PROBABILITY);
}
Also used : ReadCountCollection(org.broadinstitute.hellbender.tools.exome.ReadCountCollection) IOException(java.io.IOException) UserException(org.broadinstitute.hellbender.exceptions.UserException) BeforeClass(org.testng.annotations.BeforeClass)

Example 62 with BeforeClass

use of org.testng.annotations.BeforeClass in project gatk-protected by broadinstitute.

the class BayesianHetPulldownCalculatorUnitTest method initHeaders.

@BeforeClass
public void initHeaders() throws IOException {
    try (final SamReader normalBamReader = SamReaderFactory.makeDefault().open(NORMAL_BAM_FILE);
        final SamReader tumorBamReader = SamReaderFactory.makeDefault().open(TUMOR_BAM_FILE)) {
        normalHeader = normalBamReader.getFileHeader();
        tumorHeader = tumorBamReader.getFileHeader();
    }
}
Also used : SamReader(htsjdk.samtools.SamReader) BeforeClass(org.testng.annotations.BeforeClass)

Example 63 with BeforeClass

use of org.testng.annotations.BeforeClass in project midpoint by Evolveum.

the class SearchTest method beforeClass.

@BeforeClass
public void beforeClass() throws Exception {
    super.beforeClass();
    PrismTestUtil.resetPrismContext(MidPointPrismContextFactory.FACTORY);
    FullTextSearchConfigurationType fullTextConfig = new FullTextSearchConfigurationType();
    FullTextSearchIndexedItemsConfigurationType entry = new FullTextSearchIndexedItemsConfigurationType();
    entry.getItem().add(new ItemPath(ObjectType.F_NAME).asItemPathType());
    entry.getItem().add(new ItemPath(ObjectType.F_DESCRIPTION).asItemPathType());
    fullTextConfig.getIndexed().add(entry);
    repositoryService.applyFullTextSearchConfiguration(fullTextConfig);
    LOGGER.info("Applying full text search configuration: {}", fullTextConfig);
    List<PrismObject<? extends Objectable>> objects = prismContext.parserFor(new File(FOLDER_BASIC, "objects.xml")).parseObjects();
    objects.addAll(prismContext.parserFor(new File(FOLDER_BASIC, "objects-2.xml")).parseObjects());
    OperationResult result = new OperationResult("add objects");
    for (PrismObject object : objects) {
        repositoryService.addObject(object, null, result);
    }
    result.recomputeStatus();
    assertTrue(result.isSuccess());
}
Also used : PrismObject(com.evolveum.midpoint.prism.PrismObject) Objectable(com.evolveum.midpoint.prism.Objectable) OperationResult(com.evolveum.midpoint.schema.result.OperationResult) File(java.io.File) ItemPath(com.evolveum.midpoint.prism.path.ItemPath) BeforeClass(org.testng.annotations.BeforeClass)

Example 64 with BeforeClass

use of org.testng.annotations.BeforeClass in project gatk by broadinstitute.

the class TargetCoverageSexGenotypeCalculatorUnitTest method initSexGenotyper.

@BeforeClass
public static void initSexGenotyper() {
    final List<ContigGermlinePloidyAnnotation> contigPloidyAnnotsList;
    final ReadCountCollection readCounts;
    try {
        contigPloidyAnnotsList = ContigGermlinePloidyAnnotationTableReader.readContigGermlinePloidyAnnotationsFromFile(TEST_CONTIG_PLOIDY_ANNOTS_FILE);
        readCounts = ReadCountCollectionUtils.parse(TEST_RCC_FILE);
    } catch (final IOException ex) {
        throw new UserException.CouldNotReadInputFile("Could not read test resource files");
    }
    genotyper = new TargetCoverageSexGenotypeCalculator(readCounts, readCounts.targets(), contigPloidyAnnotsList, DEFAULT_MAPPING_ERROR_PROBABILITY);
}
Also used : ReadCountCollection(org.broadinstitute.hellbender.tools.exome.ReadCountCollection) IOException(java.io.IOException) UserException(org.broadinstitute.hellbender.exceptions.UserException) BeforeClass(org.testng.annotations.BeforeClass)

Example 65 with BeforeClass

use of org.testng.annotations.BeforeClass in project gatk by broadinstitute.

the class ContextCovariateUnitTest method init.

@BeforeClass
public void init() {
    RAC = new RecalibrationArgumentCollection();
    covariate = new ContextCovariate(RAC);
}
Also used : RecalibrationArgumentCollection(org.broadinstitute.hellbender.utils.recalibration.RecalibrationArgumentCollection) BeforeClass(org.testng.annotations.BeforeClass)

Aggregations

BeforeClass (org.testng.annotations.BeforeClass)1186 Series (com.axibase.tsd.api.model.series.Series)178 File (java.io.File)157 ArrayList (java.util.ArrayList)78 HashMap (java.util.HashMap)43 ClusterControllerManager (org.apache.helix.integration.manager.ClusterControllerManager)37 Injector (com.google.inject.Injector)36 Properties (java.util.Properties)35 Path (org.apache.hadoop.fs.Path)33 ClusterSetup (org.apache.helix.tools.ClusterSetup)33 Configuration (org.apache.hadoop.conf.Configuration)31 BigDecimal (java.math.BigDecimal)29 URL (java.net.URL)28 MockParticipantManager (org.apache.helix.integration.manager.MockParticipantManager)27 Date (java.util.Date)26 Server (org.eclipse.jetty.server.Server)25 ServerConnector (org.eclipse.jetty.server.ServerConnector)25 ODatabaseDocumentTx (com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx)23 IOException (java.io.IOException)23 Path (java.nio.file.Path)23