summaryrefslogtreecommitdiffstats
path: root/clustercontroller-core/src/test/java/com
diff options
context:
space:
mode:
authorTor Brede Vekterli <vekterli@verizonmedia.com>2021-03-18 15:18:09 +0100
committerGitHub <noreply@github.com>2021-03-18 15:18:09 +0100
commit66a0ff5bdda255b11005e4259259f74195a25186 (patch)
treefe20ccbd6d3f0613ff49243e130a5bc63c5648f1 /clustercontroller-core/src/test/java/com
parentd4c919923177e4f5ac5190d254b13831c74e0a60 (diff)
Revert "Inhibit ZooKeeper connections until our local Slobrok mirror is ready."
Diffstat (limited to 'clustercontroller-core/src/test/java/com')
-rw-r--r--clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DatabaseHandlerTest.java14
-rw-r--r--clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DummyCommunicator.java4
2 files changed, 1 insertions, 17 deletions
diff --git a/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DatabaseHandlerTest.java b/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DatabaseHandlerTest.java
index 7f664e65dc0..9c0a94309a5 100644
--- a/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DatabaseHandlerTest.java
+++ b/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DatabaseHandlerTest.java
@@ -10,7 +10,6 @@ import org.junit.Test;
import static org.hamcrest.Matchers.equalTo;
import static org.junit.Assert.assertThat;
-import static org.junit.Assert.assertTrue;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyInt;
import static org.mockito.ArgumentMatchers.eq;
@@ -66,22 +65,11 @@ public class DatabaseHandlerTest {
}
DatabaseHandler createHandler() throws Exception {
- var handler = new DatabaseHandler(mockDbFactory, mockTimer, databaseAddress, 0, monitor);
- handler.setConnectionEstablishmentIsAllowed(true);
- return handler;
+ return new DatabaseHandler(mockDbFactory, mockTimer, databaseAddress, 0, monitor);
}
}
@Test
- public void can_not_connect_to_database_if_connectivity_is_not_allowed() throws Exception {
- Fixture f = new Fixture();
- DatabaseHandler handler = f.createHandler();
- handler.setConnectionEstablishmentIsAllowed(false);
- handler.doNextZooKeeperTask(f.createMockContext());
- assertTrue(handler.isClosed()); // No connectivity allowed yet
- }
-
- @Test
public void can_store_latest_cluster_state_bundle() throws Exception {
Fixture f = new Fixture();
DatabaseHandler handler = f.createHandler();
diff --git a/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DummyCommunicator.java b/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DummyCommunicator.java
index d7bca47026f..b322c62967a 100644
--- a/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DummyCommunicator.java
+++ b/clustercontroller-core/src/test/java/com/yahoo/vespa/clustercontroller/core/DummyCommunicator.java
@@ -154,8 +154,4 @@ public class DummyCommunicator implements Communicator, NodeLookup {
return false;
}
- @Override
- public boolean isReady() {
- return true;
- }
}