use of com.yahoo.cloud.config.RoutingProviderConfig in project vespa by vespa-engine.
the class ContainerClusterTest method requireThatRoutingProviderIsDisabledForNonHosted.
@Test
public void requireThatRoutingProviderIsDisabledForNonHosted() {
DeployState state = new DeployState.Builder().properties(new DeployProperties.Builder().hostedVespa(false).build()).build(true);
MockRoot root = new MockRoot("foo", state);
ContainerCluster cluster = new ContainerCluster(root, "container0", "container1");
RoutingProviderConfig.Builder builder = new RoutingProviderConfig.Builder();
cluster.getConfig(builder);
RoutingProviderConfig config = new RoutingProviderConfig(builder);
assertFalse(config.enabled());
assertEquals(0, cluster.getAllComponents().stream().map(c -> c.getClassId().getName()).filter(c -> c.equals("com.yahoo.jdisc.http.filter.security.RoutingConfigProvider")).count());
}
Aggregations