ParallelRecompilationViewProcessWorker implements ViewProcessWorker { public synchronized void startParallel(final ViewExecutionOptions options) { setPrimary(createParallel(options)); } ParallelRecompilationViewProcessWorker(final ViewProcessWorkerFactory delegate, final ViewProcessWorkerContext context, final ViewExecutionOptions options,
      final ViewDefinition viewDefinition); synchronized void startParallel(final ViewExecutionOptions options); synchronized void startDeferred(final ViewExecutionOptions options); synchronized void startImmediate(final ViewExecutionOptions options); @Override boolean triggerCycle(); @Override boolean requestCycle(); @Override void updateViewDefinition(ViewDefinition viewDefinition); @Override void terminate(); @Override void join(); @Override boolean join(final long timeout); @Override synchronized boolean isTerminated(); @Override void forceGraphRebuild();  }
@Test(expectedExceptions = IllegalStateException.class) public void testIllegalStart_alreadyRunning() { final ViewProcessWorkerFactory workerFactory = Mockito.mock(ViewProcessWorkerFactory.class); final ViewProcessWorkerContext context = Mockito.mock(ViewProcessWorkerContext.class); final ViewExecutionOptions options = ExecutionOptions.infinite(MarketData.live(), ExecutionFlags.none().ignoreCompilationValidity().get()); final ViewDefinition viewDefinition = Mockito.mock(ViewDefinition.class); final ParallelRecompilationViewProcessWorker worker = new ParallelRecompilationViewProcessWorker(workerFactory, context, options, viewDefinition); worker.startParallel(options); worker.startParallel(options); }