@Test
 @BenchmarkOptions(benchmarkRounds = 1, warmupRounds = 0, concurrency = 1)
 public void shutdown() throws Exception {
   testRunner.start();
   ThreadHelper.sleep(3000L);
   //
   testRunner.shutdown();
   ThreadHelper.sleep(3000L);
 }
 @Test
 @BenchmarkOptions(benchmarkRounds = 1, warmupRounds = 0, concurrency = 1)
 public void start() throws Exception {
   ExecutorService executorService = Executors.newFixedThreadPool(2);
   //
   TestRunner runner = new TestRunner(executorService);
   runner.start();
   //
   runner = new TestRunner(executorService);
   runner.start();
   ThreadHelper.sleep(10 * 1000L);
 }
예제 #3
0
  @Test
  public void testImage01() throws Exception {
    byte[] stdout = TestHelper.readFile("../docs/examples/images_01/01/output-jhove.raw");
    List<ResultTransformer.Entry> transformedData =
        jhoveMetadataTransformer.transform(stdout, null);
    ArrayList ignoredProperties = (ArrayList) image01Test02.get("ignoredSignificantProperties");
    ArrayList recognizedProperties =
        (ArrayList) image01Test02.get("recognizedSignificantProperties");
    LinkedHashMap<String, Object> specialProperties =
        (LinkedHashMap) image01Test02.get("specialSignificantProperties");
    LinkedHashMap significantProperties =
        (LinkedHashMap) image01Test02.get("significantProperties");

    t.runStandardTests(
        transformedData,
        recognizedProperties,
        ignoredProperties,
        specialProperties,
        extractorSignificantProperties,
        significantProperties,
        thisExtractor);
  }