26 |
|
} |
27 |
|
|
28 |
|
// Runs with "mainPool" use > 1 thread. singletonPool tests use 1 |
29 |
< |
static final int mainPoolSize = |
29 |
> |
static final int mainPoolSize = |
30 |
|
Math.max(2, Runtime.getRuntime().availableProcessors()); |
31 |
|
|
32 |
|
private static ForkJoinPool mainPool() { |
438 |
|
assertTrue(cause instanceof FJException); |
439 |
|
assertTrue(f.isDone()); |
440 |
|
assertTrue(f.isCompletedAbnormally()); |
441 |
< |
assertSame(cause, f.getException()); |
441 |
> |
assertSame(cause.getClass(), f.getException().getClass()); |
442 |
|
} |
443 |
|
}}; |
444 |
|
testInvokeOnPool(mainPool(), a); |
460 |
|
assertTrue(cause instanceof FJException); |
461 |
|
assertTrue(f.isDone()); |
462 |
|
assertTrue(f.isCompletedAbnormally()); |
463 |
< |
assertSame(cause, f.getException()); |
463 |
> |
assertSame(cause.getClass(), f.getException().getClass()); |
464 |
|
} |
465 |
|
}}; |
466 |
|
testInvokeOnPool(mainPool(), a); |
1166 |
|
assertTrue(cause instanceof FJException); |
1167 |
|
assertTrue(f.isDone()); |
1168 |
|
assertTrue(f.isCompletedAbnormally()); |
1169 |
< |
assertSame(cause, f.getException()); |
1169 |
> |
assertSame(cause.getClass(), f.getException().getClass()); |
1170 |
|
} |
1171 |
|
}}; |
1172 |
|
testInvokeOnPool(singletonPool(), a); |
1188 |
|
assertTrue(cause instanceof FJException); |
1189 |
|
assertTrue(f.isDone()); |
1190 |
|
assertTrue(f.isCompletedAbnormally()); |
1191 |
< |
assertSame(cause, f.getException()); |
1191 |
> |
assertSame(cause.getClass(), f.getException().getClass()); |
1192 |
|
} |
1193 |
|
}}; |
1194 |
|
testInvokeOnPool(singletonPool(), a); |