Exemplo n.º 1
0
    def testReboot(self, getStubMock):
        stubMock = mock.Mock()
        stubMock.Reboot.return_value = host_pb2.HostRebootResponse()
        getStubMock.return_value = stubMock

        host = opencue.wrappers.host.Host(host_pb2.Host(name=TEST_HOST_NAME))
        host.reboot()

        stubMock.Reboot.assert_called_with(
            host_pb2.HostRebootRequest(host=host.data), timeout=mock.ANY)
Exemplo n.º 2
0
 def reboot(self):
     """Causes the host to kill all running frames and reboot the machine."""
     self.stub.Reboot(host_pb2.HostRebootRequest(host=self.data),
                      timeout=Cuebot.Timeout)