check mode in tx test cases

This commit is contained in:
Grahame Grieve 2024-10-22 17:16:27 +10:30
parent 9dc08c213c
commit c9c04aec3b
1 changed files with 6 additions and 4 deletions

View File

@ -180,10 +180,12 @@ public class TxTester {
List<Resource> setup = loadSetupResources(suite);
boolean ok = true;
for (JsonObject test : suite.getJsonObjects("tests")) {
if (test.asBoolean("disabled")) {
ok = true;
} else {
ok = runTest(test, tx, setup, modes, filter, outputS.forceArray("tests")) && ok;
if ((!test.has("mode") || modes.contains(test.asString("mode")))) {
if (test.asBoolean("disabled")) {
ok = true;
} else {
ok = runTest(test, tx, setup, modes, filter, outputS.forceArray("tests")) && ok;
}
}
}
return ok;