Пример #1
0
    def test_write_with_args(self):
        stream = utils.BytearrayStream()
        payload = rekey_key_pair.RekeyKeyPairRequestPayload(
            self.private_key_uuid, self.offset, self.common_template_attribute,
            self.private_key_template_attribute,
            self.public_key_template_attribute)

        self._test_write(stream, payload, self.encoding_full)
Пример #2
0
    def test_read_with_args(self):
        stream = self.encoding_full
        payload = rekey_key_pair.RekeyKeyPairRequestPayload()

        self._test_read(stream, payload, self.private_key_uuid, self.offset,
                        self.common_template_attribute,
                        self.private_key_template_attribute,
                        self.public_key_template_attribute)
Пример #3
0
 def _build_rekey_key_pair_batch_item(self,
                                      private_key_uuid=None, offset=None,
                                      common_template_attribute=None,
                                      private_key_template_attribute=None,
                                      public_key_template_attribute=None):
     operation = Operation(OperationEnum.REKEY_KEY_PAIR)
     payload = rekey_key_pair.RekeyKeyPairRequestPayload(
         private_key_uuid, offset,
         common_template_attribute=common_template_attribute,
         private_key_template_attribute=private_key_template_attribute,
         public_key_template_attribute=public_key_template_attribute)
     batch_item = messages.RequestBatchItem(
         operation=operation, request_payload=payload)
     return batch_item
Пример #4
0
 def _create_rekey_key_pair_payload(self):
     return rekey_key_pair.RekeyKeyPairRequestPayload()
Пример #5
0
 def test_init_with_args(self):
     rekey_key_pair.RekeyKeyPairRequestPayload(
         self.private_key_uuid, self.offset, self.common_template_attribute,
         self.private_key_template_attribute,
         self.public_key_template_attribute)
Пример #6
0
 def test_init_with_none(self):
     rekey_key_pair.RekeyKeyPairRequestPayload()
Пример #7
0
    def test_write_with_none(self):
        stream = utils.BytearrayStream()
        payload = rekey_key_pair.RekeyKeyPairRequestPayload()

        self._test_write(stream, payload, self.encoding_empty)
Пример #8
0
    def test_read_with_none(self):
        stream = self.encoding_empty
        payload = rekey_key_pair.RekeyKeyPairRequestPayload()

        self._test_read(stream, payload, None, None, None, None, None)