示例#1
0
    def setBurst(self, burst):
        """Sets subscription burst size; the number of cores the show is allowed to burst to.

        :type  burst: int
        :param burst: the new burst size
        """
        assert (isinstance(burst, int)), "burst is not expected type: int"
        self.stub.SetBurst(subscription_pb2.SubscriptionSetBurstRequest(
            subscription=self.data, burst=burst),
                           timeout=Cuebot.Timeout)
示例#2
0
    def testSetBurst(self, getStubMock):
        stubMock = mock.Mock()
        stubMock.SetBurst.return_value = subscription_pb2.SubscriptionSetBurstResponse(
        )
        getStubMock.return_value = stubMock

        subscription = opencue.wrappers.subscription.Subscription(
            subscription_pb2.Subscription(name='testSubscription'))
        subscription.setBurst(15)

        stubMock.SetBurst.assert_called_with(
            subscription_pb2.SubscriptionSetBurstRequest(
                subscription=subscription.data, burst=15),
            timeout=mock.ANY)
示例#3
0
 def setBurst(self, burst):
     self.stub.SetBurst(subscription_pb2.SubscriptionSetBurstRequest(
         subscription=self.data, burst=burst),
                        timeout=Cuebot.Timeout)
示例#4
0
 def setBurst(self, burst):
     assert (isinstance(burst, int)), "burst is not expected type: int"
     self.stub.SetBurst(subscription_pb2.SubscriptionSetBurstRequest(
         subscription=self.data, burst=burst),
                        timeout=Cuebot.Timeout)