From 764de1a89760a26d4285a1c2274ea56eab584e79 Mon Sep 17 00:00:00 2001 From: Harald Musum Date: Fri, 8 Jul 2022 12:38:40 +0200 Subject: Remove testing of standalone docproc container This has not been supported for a long time, removing. --- .../docproc/StandaloneDocprocContainerTest.java | 82 ---------------------- 1 file changed, 82 deletions(-) delete mode 100644 config-model/src/test/java/com/yahoo/vespa/model/container/docproc/StandaloneDocprocContainerTest.java (limited to 'config-model') diff --git a/config-model/src/test/java/com/yahoo/vespa/model/container/docproc/StandaloneDocprocContainerTest.java b/config-model/src/test/java/com/yahoo/vespa/model/container/docproc/StandaloneDocprocContainerTest.java deleted file mode 100644 index 5bb93255a8f..00000000000 --- a/config-model/src/test/java/com/yahoo/vespa/model/container/docproc/StandaloneDocprocContainerTest.java +++ /dev/null @@ -1,82 +0,0 @@ -// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. -package com.yahoo.vespa.model.container.docproc; - -import com.yahoo.component.ComponentId; -import com.yahoo.config.model.deploy.DeployState; -import com.yahoo.config.model.builder.xml.test.DomBuilderTest; -import com.yahoo.vespa.model.container.ContainerCluster; -import com.yahoo.vespa.model.container.ContainerModel; -import com.yahoo.vespa.model.container.component.Component; -import com.yahoo.vespa.model.container.xml.ContainerModelBuilder; -import com.yahoo.vespa.model.container.xml.ContainerModelBuilder.Networking; -import org.junit.Test; -import org.w3c.dom.Element; - -import java.util.Map; - -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertTrue; - -/** - * @author Einar M R Rosenvinge - */ -public class StandaloneDocprocContainerTest extends DomBuilderTest { - - public ContainerCluster setupCluster(boolean standalone) { - ContainerModelBuilder builder = new ContainerModelBuilder(standalone, Networking.disable); - ContainerModel model = builder.build(DeployState.createTestState(), null, null, root, servicesXml()); - - if (!standalone) - model.getCluster().getDocproc().getChains().addServersAndClientsForChains(); - - root.freezeModelTopology(); - return model.getCluster(); - } - - private Element servicesXml() { - return parse("" + - "\n" + - " \n" + - " \n" + - " \n" + - " \n" + - " \n" + - " \n" + - " \n" + - " \n" + - "\n"); - } - - @Test - public void requireMbusProvidersWhenNonStandalone() { - ContainerCluster containerCluster = setupCluster(false); - Map> components = containerCluster.getComponentsMap(); - - boolean foundAtLeastOneClient = false; - boolean foundAtLeastOneServer = false; - - for (ComponentId componentId : components.keySet()) { - if (componentId.stringValue().contains("MbusClient")) foundAtLeastOneClient = true; - if (componentId.stringValue().contains("MbusServer")) foundAtLeastOneServer = true; - } - assertTrue(foundAtLeastOneClient); - assertTrue(foundAtLeastOneServer); - - } - - @Test - public void requireNoMbusProvidersWhenStandalone() { - ContainerCluster containerCluster = setupCluster(true); - Map> components = containerCluster.getComponentsMap(); - - boolean foundAtLeastOneClient = false; - boolean foundAtLeastOneServer = false; - - for (ComponentId componentId : components.keySet()) { - if (componentId.stringValue().contains("MbusClient")) foundAtLeastOneClient = true; - if (componentId.stringValue().contains("MbusServer")) foundAtLeastOneServer = true; - } - assertFalse(foundAtLeastOneClient); - assertFalse(foundAtLeastOneServer); - } -} -- cgit v1.2.3