### Question:
ComparisonExecutor { public boolean areAllComparisonCalculationsFinished() { return asyncComparisonExecutor.getActiveCount() == 0; } ComparisonExecutor(AliasResolver aliasResolver);   ComparisonExecutor(ThreadPoolExecutor executorService, AliasResolver aliasResolver); void scheduleAllConfiguredComparisonsForOneBuild(String baseBranchName, String baseBuildName); Future<BuildDiffInfo> scheduleComparison(String baseBranchName, String baseBuildName,
													String comparisonBranchName, String comparisonBuildName, String comparisonName); void executeAfterAllPendingComparisonsDone(Runnable task); boolean areAllComparisonCalculationsFinished();  }### Answer:
@Test void testAreAllComparisonCalculationsFinishedWithNoRunningThreadsReturnsTrue() { when(threadPoolExecutor.getActiveCount()).thenReturn(0); assertTrue(comparisonExecutor.areAllComparisonCalculationsFinished()); }
@Test void testAreAllComparisonCalculationsFinishedWithRunningThreadsReturnsFalse() { when(threadPoolExecutor.getActiveCount()).thenReturn(1); assertFalse(comparisonExecutor.areAllComparisonCalculationsFinished()); }