ValidateInterpretation implements Callable<Integer> { public ValidateInterpretation(final File expectedFile, final File observedFile, final File outputFile, final int resolution, final List<String> loci, final boolean printSummary, final GlClient glclient) { checkNotNull(loci); checkNotNull(glclient); checkArgument(expectedFile != null || observedFile != null, "at least one of expected or observed file must not be null"); checkArgument(resolution > 0 && resolution < 5, "resolution must be in the range [1..4]"); this.observedFile = observedFile; this.expectedFile = expectedFile; this.outputFile = outputFile; this.resolution = resolution; this.loci = loci; this.printSummary = printSummary; this.glclient = glclient; } ValidateInterpretation(final File expectedFile,
                                  final File observedFile,
                                  final File outputFile,
                                  final int resolution,
                                  final List<String> loci,
                                  final boolean printSummary,
                                  final GlClient glclient); @Override Integer call(); static void main(final String[] args);  }
@Test public void testValidateInterpretation() throws Exception { copyResource("expected.txt", expectedFile); copyResource("observed.txt", observedFile); Integer result = validateInterpretation.call(); for (String output : Files.readLines(outputFile, Charsets.UTF_8)) { assertTrue(output.startsWith("PASS")); } }