use of org.broadinstitute.hellbender.utils.gcs.GATKGCSOptions in project gatk by broadinstitute.
the class ReferenceAPISourceUnitTest method setupPipeline.
private Pipeline setupPipeline() {
// We create GATKGCSOptions instead of DataflowPipelineOptions to keep track of the secrets
// so we can read the reference.
final GATKGCSOptions options = PipelineOptionsFactory.as(GATKGCSOptions.class);
options.setProject(getGCPTestProject());
if (getGCPTestApiKey() != null) {
options.setApiKey(getGCPTestApiKey());
// put a serialized version of the credentials in the pipelineOptions, so we can get to it later.
try {
GenomicsFactory.OfflineAuth auth = GCSOptions.Methods.createGCSAuth(options);
GATKGCSOptions.Methods.setOfflineAuth(options, auth);
} catch (Exception x) {
throw new GATKException("Error with credentials", x);
}
}
// We don't use GATKTestPipeline because we need specific options.
return TestPipeline.create(options);
}
Aggregations