public static class VCFHeaderTest2Walker extends VCFHeaderTestWalker {}
@Test
public void testAddingVCFHeaderInfo() {
final VCFHeader header = new VCFHeader();
final Walker walker1 = new VCFHeaderTestWalker();
final Walker walker2 = new VCFHeaderTest2Walker();
final GenomeAnalysisEngine testEngine1 = new GenomeAnalysisEngine();
testEngine1.setWalker(walker1);
final GenomeAnalysisEngine testEngine2 = new GenomeAnalysisEngine();
testEngine2.setWalker(walker2);
final VCFHeaderLine line1 = GATKVCFUtils.getCommandLineArgumentHeaderLine(testEngine1, Collections.EMPTY_LIST);
logger.warn(line1);
Assert.assertNotNull(line1);
Assert.assertEquals(line1.getKey(), GATKVCFUtils.GATK_COMMAND_LINE_KEY);
for ( final String field : Arrays.asList("Version", "ID", "Date", "CommandLineOptions"))
Assert.assertTrue(line1.toString().contains(field), "Couldn't find field " + field + " in " + line1.getValue());
Assert.assertTrue(line1.toString().contains("ID=" + testEngine1.getWalkerName()));
final VCFHeaderLine line2 = GATKVCFUtils.getCommandLineArgumentHeaderLine(testEngine2, Collections.EMPTY_LIST);
logger.warn(line2);
header.addMetaDataLine(line1);
final Set<VCFHeaderLine> lines1 = header.getMetaDataInInputOrder();
Assert.assertTrue(lines1.contains(line1));
header.addMetaDataLine(line2);
final Set<VCFHeaderLine> lines2 = header.getMetaDataInInputOrder();
Assert.assertTrue(lines2.contains(line1));
Assert.assertTrue(lines2.contains(line2));
}