Search in sources :

Example 1 with VmNicDao

use of org.ovirt.engine.core.dao.network.VmNicDao in project ovirt-engine by oVirt.

the class RunVmValidatorTest method testBootFromNetworkNoNetwork.

@Test
public void testBootFromNetworkNoNetwork() {
    VmNicDao dao = mock(VmNicDao.class);
    doReturn(dao).when(runVmValidator).getVmNicDao();
    VM vm = new VM();
    vm.setBootSequence(BootSequence.N);
    validateResult(runVmValidator.validateBootSequence(vm, new ArrayList<>()), false, EngineMessage.VM_CANNOT_RUN_FROM_NETWORK_WITHOUT_NETWORK);
}
Also used : VM(org.ovirt.engine.core.common.businessentities.VM) ArrayList(java.util.ArrayList) VmNicDao(org.ovirt.engine.core.dao.network.VmNicDao) Test(org.junit.Test)

Aggregations

ArrayList (java.util.ArrayList)1 Test (org.junit.Test)1 VM (org.ovirt.engine.core.common.businessentities.VM)1 VmNicDao (org.ovirt.engine.core.dao.network.VmNicDao)1