### Question:
JobIDParser { abstract List<String> parseJobID() throws IOException; JobIDParser(String statusdir, Configuration conf);   }### Answer:
@Test public void testParsePig() throws IOException { String errFileName = "src/test/data/status/pig"; PigJobIDParser pigJobIDParser = new PigJobIDParser(errFileName, new Configuration()); List<String> jobs = pigJobIDParser.parseJobID(); Assert.assertEquals(jobs.size(), 1); }
@Test public void testParseHive() throws IOException { String errFileName = "src/test/data/status/hive"; HiveJobIDParser hiveJobIDParser = new HiveJobIDParser(errFileName, new Configuration()); List<String> jobs = hiveJobIDParser.parseJobID(); Assert.assertEquals(jobs.size(), 1); }
@Test public void testParseJar() throws IOException { String errFileName = "src/test/data/status/jar"; JarJobIDParser jarJobIDParser = new JarJobIDParser(errFileName, new Configuration()); List<String> jobs = jarJobIDParser.parseJobID(); Assert.assertEquals(jobs.size(), 1); }
@Test public void testParseStreaming() throws IOException { String errFileName = "src/test/data/status/streaming"; JarJobIDParser jarJobIDParser = new JarJobIDParser(errFileName, new Configuration()); List<String> jobs = jarJobIDParser.parseJobID(); Assert.assertEquals(jobs.size(), 1); }