use of com.github.lindenb.jvarkit.tools.vcfamalgation.VcfXmlAmalgamation in project jvarkit by lindenb.
the class TestNg01 method testVcfAmalgation.
@Test
public void testVcfAmalgation() throws IOException {
final File tmpXml = File.createTempFile("_tmp", ".xml", TEST_RESULTS_DIR);
PrintWriter pw = new PrintWriter(tmpXml);
pw.println("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<config>\n" + "<vcfhead><count>10</count></vcfhead>" + "<vcffilterjdk><filter>ODD</filter><expression>return variant.getStart()%2==0;</expression></vcffilterjdk>" + "<vcftail><count>5</count></vcftail>" + "</config>");
pw.flush();
pw.close();
final File output = new File(TEST_RESULTS_DIR, "jeter.vcf");
Assert.assertEquals(0, new VcfXmlAmalgamation().instanceMain(new String[] { "-o", output.getPath(), "--xml", tmpXml.getPath(), VCF01 }));
Assert.assertTrue(output.delete());
tmpXml.delete();
}
Aggregations