@Test
    void two_clusters_with_clashing_cluster_names_throws_exception_when_hosted() throws IOException, SAXException {
        String servicesXml = """
                             <services version='1.0'>
                               <container id='c-1' version='1.0'>
                                 <nodes count='1' />
                               </container>
                               <container id='c_1' version='1.0'>
                                 <nodes count='1' />
                               </container>
                             </services>
                             """;

        assertEquals("container clusters 'c-1' and 'c_1' have clashing endpoint names, when '_' is replaced with '-' to form valid domain names",
                     assertThrows(IllegalArgumentException.class,
                                  () ->
                                          new VespaModel(new NullConfigModelRegistry(), new DeployState.Builder()
                                                  .modelHostProvisioner(new InMemoryProvisioner(4, false))
                                                  .applicationPackage(new MockApplicationPackage.Builder().withServices(servicesXml).build())
                                                  .properties(new TestProperties().setHostedVespa(true))
                                                  .build()))
                             .getMessage());

        new VespaModel(new NullConfigModelRegistry(), new DeployState.Builder()
                .modelHostProvisioner(new InMemoryProvisioner(4, false))
                .applicationPackage(new MockApplicationPackage.Builder().withServices(servicesXml).build())
                .properties(new TestProperties().setHostedVespa(false))
                .build());
    }
Tests for "core functionality" of the container model, e.g. ports, or the 'components' and 'bundles' configs.

Before adding a new test to this class, check if the test fits into one of the other existing subclasses
of {@link ContainerModelBuilderTestBase}. If not, consider creating a new subclass.

@author gjoranv
config-model/src/test/java/com/yahoo/vespa/model/container/xml/ContainerModelBuilderTest.java