PublicIpAddress answer = modelImpl.getSourceNatIpAddressForGuestNetwork(fakeAccount, fakeNetwork);
Assert.assertNull(answer);
IPAddressVO fakeIp2 = new IPAddressVO(new Ip("76.75.75.75"), 1, 0xaabb10ddeeffL, 10, true);
fakeList.add(fakeIp2);
when (
ipAddressDao.findById(anyLong())
).thenReturn(fakeIp2);
answer = modelImpl.getSourceNatIpAddressForGuestNetwork(fakeAccount, fakeNetwork);
Assert.assertNotNull(answer);
Assert.assertEquals(answer.getAddress().addr(), "76.75.75.75");