Fix 0 case terminology cache test (intermittent test failure)
This commit is contained in:
parent
7a7e3240b4
commit
cc6ee9216c
|
@ -426,8 +426,10 @@ public class TerminologyCacheTests {
|
|||
String extracted = cache.extracted(json, vs);
|
||||
|
||||
JsonElement element = jsonParser.parse(extracted);
|
||||
assertEquals(max, element.getAsJsonObject().getAsJsonObject("expansion").getAsJsonArray("contains").size());
|
||||
|
||||
final int expansionSize = element.getAsJsonObject().has("expansion")
|
||||
? element.getAsJsonObject().getAsJsonObject("expansion").getAsJsonArray("contains").size()
|
||||
: 0;
|
||||
assertEquals(max, expansionSize);
|
||||
}
|
||||
|
||||
@ParameterizedTest
|
||||
|
|
Loading…
Reference in New Issue