@Test
public void configureIpAndMaskOnNicWithIpAddressNullOrNotNullTestIpAddressNotNull() {

    StringBuilder buf = new StringBuilder();
    NicProfile nic = Mockito.mock(NicProfile.class);
    Mockito.when(nic.getIPv4Address()).thenReturn("ipv4Address");
    Mockito.when(nic.getIPv4Netmask()).thenReturn("ipv4Netmask");
    spy.configureIpAndMaskOnNicWithIpAddressNullOrNotNull(buf, nic, 0);
    Assert.assertEquals(" eth0ip=ipv4Address eth0mask=ipv4Netmask", buf.toString());
}