return newFixedThreadPool(concurrent.count(), new ConcurrentTestRunnerThreadFactory());
return newCachedThreadPool(new ConcurrentTestRunnerThreadFactory());
}
private static Concurrent findConcurrentClass(Class<?> type) {
Concurrent concurrent = null;
while (concurrent == null && type.getSuperclass() != null) {
concurrent = type.getAnnotation(Concurrent.class);
type = type.getSuperclass();
}
return concurrent;