diff --git a/src/test/java/org/opensearch/knn/index/KNNSettingsTests.java b/src/test/java/org/opensearch/knn/index/KNNSettingsTests.java index 75eabc7a3..724c9ad6a 100644 --- a/src/test/java/org/opensearch/knn/index/KNNSettingsTests.java +++ b/src/test/java/org/opensearch/knn/index/KNNSettingsTests.java @@ -45,7 +45,7 @@ public void testGetSettingValueFromConfig() { long actualKNNCircuitBreakerLimit = ((ByteSizeValue) KNNSettings.state() .getSettingValue(KNNSettings.KNN_MEMORY_CIRCUIT_BREAKER_LIMIT)).getKb(); mockNode.close(); - assertEquals(actualKNNCircuitBreakerLimit, expectedKNNCircuitBreakerLimit); + assertEquals(expectedKNNCircuitBreakerLimit, actualKNNCircuitBreakerLimit); } @SneakyThrows @@ -58,9 +58,10 @@ public void testGetSettingValueDefault() { .getSettingValue(KNNSettings.KNN_MEMORY_CIRCUIT_BREAKER_LIMIT)).getKb(); mockNode.close(); assertEquals( - actualKNNCircuitBreakerLimit, ((ByteSizeValue) KNNSettings.dynamicCacheSettings.get(KNNSettings.KNN_MEMORY_CIRCUIT_BREAKER_LIMIT).getDefault(Settings.EMPTY)) - .getKb() + .getKb(), + actualKNNCircuitBreakerLimit + ); }