def removeTags(self, tags): """Remove tags from this host @type tags: list<str> @param tags: The tags to remove """ self.stub.RemoveTags(host_pb2.HostRemoveTagsRequest(host=self.data, tags=tags), timeout=Cuebot.Timeout)
def testRemoveTags(self, getStubMock): stubMock = mock.Mock() stubMock.RemoveTags.return_value = host_pb2.HostRemoveTagsResponse() getStubMock.return_value = stubMock tags = ['tags', 'are', 'fun'] host = opencue.wrappers.host.Host(host_pb2.Host(name=TEST_HOST_NAME)) host.removeTags(tags) stubMock.RemoveTags.assert_called_with(host_pb2.HostRemoveTagsRequest( host=host.data, tags=tags), timeout=mock.ANY)