/**
* Test method for {@link org.jboss.services.binding.ServiceBindingMetadata#ServiceBindingMetadata(java.lang.String, java.lang.String, java.lang.String, int, boolean, boolean)}.
*/
public void testServiceBindingMetadataStringStringStringIntBooleanBoolean()
{
ServiceBindingMetadata md = new ServiceBindingMetadata(S, B, H, 1, true, true);
assertEquals(S, md.getServiceName());
assertEquals(B, md.getBindingName());
assertEquals(H, md.getHostName());
assertEquals(1, md.getPort());
assertTrue(md.isFixedPort());
assertTrue(md.isFixedHostName());
md = new ServiceBindingMetadata(S, null, null, 1, true, true);
assertEquals(S, md.getServiceName());
assertEquals(null, md.getBindingName());
assertEquals(null, md.getHostName());
assertEquals(1, md.getPort());
assertTrue(md.isFixedPort());
assertTrue(md.isFixedHostName());
try
{
md = new ServiceBindingMetadata(null, B, H, 1, true, true);
fail("null serviceName allowed");
}
catch (IllegalArgumentException good) {}
}