From c6f60ca00e866e3d05c0f19df37a1a48af0b1032 Mon Sep 17 00:00:00 2001 From: Alexey Andreev Date: Tue, 17 Oct 2023 10:04:57 +0200 Subject: [PATCH] junit: fix crash when test runner is not configured --- .../junit/src/main/java/org/teavm/junit/TeaVMTestRunner.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/junit/src/main/java/org/teavm/junit/TeaVMTestRunner.java b/tools/junit/src/main/java/org/teavm/junit/TeaVMTestRunner.java index 2729c714a..8f653f1d1 100644 --- a/tools/junit/src/main/java/org/teavm/junit/TeaVMTestRunner.java +++ b/tools/junit/src/main/java/org/teavm/junit/TeaVMTestRunner.java @@ -111,7 +111,9 @@ public class TeaVMTestRunner extends Runner implements Filterable { for (var platform : platforms) { var runStrategy = platform.createRunStrategy(outputDir); - runners.put(platform.getPlatform(), runStrategy); + if (runStrategy != null) { + runners.put(platform.getPlatform(), runStrategy); + } } for (var strategy : runners.values()) {