Moti Asayag has uploaded a new change for review. Change subject: engine: Fix broken test ......................................................................
engine: Fix broken test Change-Id: I8ae38a29c2e87d89a31274ce742c29471c127659 Signed-off-by: Moti Asayag <[email protected]> --- M backend/manager/modules/bll/src/test/java/org/ovirt/engine/core/bll/StartVdsCommandTest.java 1 file changed, 8 insertions(+), 9 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/08/37608/1 diff --git a/backend/manager/modules/bll/src/test/java/org/ovirt/engine/core/bll/StartVdsCommandTest.java b/backend/manager/modules/bll/src/test/java/org/ovirt/engine/core/bll/StartVdsCommandTest.java index ebf1ecb..3c1be8f 100644 --- a/backend/manager/modules/bll/src/test/java/org/ovirt/engine/core/bll/StartVdsCommandTest.java +++ b/backend/manager/modules/bll/src/test/java/org/ovirt/engine/core/bll/StartVdsCommandTest.java @@ -5,7 +5,13 @@ import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; import static org.mockito.Matchers.any; +import static org.mockito.Matchers.eq; import static org.mockito.Mockito.doNothing; +import static org.mockito.Mockito.doReturn; +import static org.mockito.Mockito.spy; +import static org.mockito.Mockito.stub; +import static org.mockito.Mockito.times; +import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; import java.util.LinkedList; @@ -41,13 +47,6 @@ import org.ovirt.engine.core.dao.VdsGroupDAO; import org.ovirt.engine.core.dao.VmDAO; import org.ovirt.engine.core.utils.MockConfigRule; - -import static org.mockito.Mockito.doReturn; -import static org.mockito.Mockito.spy; -import static org.mockito.Mockito.stub; -import static org.mockito.Mockito.eq; -import static org.mockito.Mockito.verify; -import static org.mockito.Mockito.times; @RunWith(MockitoJUnitRunner.class) public class StartVdsCommandTest { @@ -160,7 +159,7 @@ retValue.setSucceeded(true); FenceStatusReturnValue stat = new FenceStatusReturnValue(status, ""); retValue.setReturnValue(stat); - when(executor.checkStatus()).thenReturn(retValue); + when(executor.checkHostStatus()).thenReturn(retValue); } private VDSFenceReturnValue createStatus(String value) { @@ -285,7 +284,7 @@ public void onFailureRetryWaitForStatus() { mockVdsSingleAgent(); mockExecutor(agent1, true); - when(executor.checkStatus()).thenReturn(createStatus("off")).thenReturn(createStatus("on")); + when(executor.checkHostStatus()).thenReturn(createStatus("off")).thenReturn(createStatus("on")); command.executeCommand(); assertTrue(command.getSucceeded()); } -- To view, visit http://gerrit.ovirt.org/37608 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I8ae38a29c2e87d89a31274ce742c29471c127659 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Moti Asayag <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
