mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 18:58:00 +00:00
Update FCollectionTest.java
prior to the threadsafeiterable restoration
This commit is contained in:
@@ -48,7 +48,7 @@ public class FCollectionTest {
|
|||||||
cards.add(new Card(i, null));
|
cards.add(new Card(i, null));
|
||||||
CardCollection cc = new CardCollection(cards);
|
CardCollection cc = new CardCollection(cards);
|
||||||
List<CompletableFuture<Integer>> futures = new ArrayList<>();
|
List<CompletableFuture<Integer>> futures = new ArrayList<>();
|
||||||
for (Card c : cc) {
|
for (Card c : cc.threadSafeIterable()) {
|
||||||
futures.add(CompletableFuture.supplyAsync(() -> {
|
futures.add(CompletableFuture.supplyAsync(() -> {
|
||||||
if (c.getId() % 2 > 0)
|
if (c.getId() % 2 > 0)
|
||||||
cc.remove(c);
|
cc.remove(c);
|
||||||
|
|||||||
Reference in New Issue
Block a user