From 65f587f54a3657e4ce5129b276f2a2b3ef06a3ba Mon Sep 17 00:00:00 2001 From: Hamado Dene Date: Wed, 21 Feb 2024 16:31:20 +0100 Subject: [PATCH] Fix test --- .../org/carapaceproxy/core/RuntimeServerConfiguration.java | 2 +- .../test/java/org/carapaceproxy/ApplyConfigurationTest.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/carapace-server/src/main/java/org/carapaceproxy/core/RuntimeServerConfiguration.java b/carapace-server/src/main/java/org/carapaceproxy/core/RuntimeServerConfiguration.java index 429ab6e31..dc2b77681 100644 --- a/carapace-server/src/main/java/org/carapaceproxy/core/RuntimeServerConfiguration.java +++ b/carapace-server/src/main/java/org/carapaceproxy/core/RuntimeServerConfiguration.java @@ -212,7 +212,7 @@ public void configure(ConfigurationStore properties) throws ConfigurationNotVali healthConnectTimeout = properties.getInt("healthmanager.connecttimeout", healthConnectTimeout); LOG.log(Level.INFO, "healthmanager.connecttimeout={0}", healthConnectTimeout); - if(healthConnectTimeout < 0) { + if (healthConnectTimeout < 0) { throw new ConfigurationNotValidException("Invalid value '" + this.healthConnectTimeout + "' for healthmanager.connecttimeout. ConnectTimeout cannot be negative"); } diff --git a/carapace-server/src/test/java/org/carapaceproxy/ApplyConfigurationTest.java b/carapace-server/src/test/java/org/carapaceproxy/ApplyConfigurationTest.java index d42b540de..eb76e440a 100644 --- a/carapace-server/src/test/java/org/carapaceproxy/ApplyConfigurationTest.java +++ b/carapace-server/src/test/java/org/carapaceproxy/ApplyConfigurationTest.java @@ -377,7 +377,7 @@ public void testChangeBackendHealthManagerConfiguration() throws Exception { { Properties configuration = new Properties(); - configuration.put("connectionsmanager.connecttimeout", "9479"); + configuration.put("healthmanager.connecttimeout", "9479"); server.configureAtBoot(new PropertiesConfigurationStore(configuration)); } server.start(); @@ -386,7 +386,7 @@ public void testChangeBackendHealthManagerConfiguration() throws Exception { // change configuration { Properties configuration = new Properties(); - configuration.put("connectionsmanager.connecttimeout", "9233"); + configuration.put("healthmanager.connecttimeout", "9233"); reloadConfiguration(configuration, server); assertEquals(9233, server.getBackendHealthManager().getConnectTimeout());