Exemplo n.º 1
0
 def testAccessors(self):
     """Test for SignatureValue accessors"""
     self.signature_value.id = "id"
     self.signature_value.text = "signature value"
     new_signature_value = ds.signature_value_from_string(self.signature_value.to_string())
     assert new_signature_value.id == "id"
     assert new_signature_value.text.strip() == "signature value"
Exemplo n.º 2
0
 def testAccessors(self):
   """Test for SignatureValue accessors"""
   self.signature_value.id = "id"
   self.signature_value.text = "signature value"
   new_signature_value = ds.signature_value_from_string(
     self.signature_value.to_string())
   assert new_signature_value.id == "id"
   assert new_signature_value.text.strip() == "signature value"
Exemplo n.º 3
0
    def testAccessors(self):
        """Test for Signature accessors"""
        self.signature.id = "id"
        self.signature.signed_info = ds.signed_info_from_string(ds_data.TEST_SIGNED_INFO)
        self.signature.signature_value = ds.signature_value_from_string(ds_data.TEST_SIGNATURE_VALUE)
        self.signature.key_info = ds.key_info_from_string(ds_data.TEST_KEY_INFO)
        self.signature.object.append(ds.object_from_string(ds_data.TEST_OBJECT))

        new_signature = ds.signature_from_string(self.signature.to_string())
        assert new_signature.id == "id"
        assert isinstance(new_signature.signed_info, ds.SignedInfo)
        assert isinstance(new_signature.signature_value, ds.SignatureValue)
        assert isinstance(new_signature.key_info, ds.KeyInfo)
        assert isinstance(new_signature.object[0], ds.Object)
Exemplo n.º 4
0
  def testAccessors(self):
    """Test for Signature accessors"""
    self.signature.id = "id"
    self.signature.signed_info = ds.signed_info_from_string(
      ds_data.TEST_SIGNED_INFO)
    self.signature.signature_value = ds.signature_value_from_string(
      ds_data.TEST_SIGNATURE_VALUE)
    self.signature.key_info = ds.key_info_from_string(ds_data.TEST_KEY_INFO)
    self.signature.object.append(ds.object_from_string(ds_data.TEST_OBJECT))

    new_signature = ds.signature_from_string(self.signature.to_string())
    assert new_signature.id == "id"
    assert isinstance(new_signature.signed_info, ds.SignedInfo)
    assert isinstance(new_signature.signature_value, ds.SignatureValue)
    assert isinstance(new_signature.key_info, ds.KeyInfo)
    assert isinstance(new_signature.object[0], ds.Object)
Exemplo n.º 5
0
 def testUsingTestData(self):
     """Test for signature_value_from_string() using test data"""
     new_signature_value = ds.signature_value_from_string(ds_data.TEST_SIGNATURE_VALUE)
     assert new_signature_value.id == "id"
     assert new_signature_value.text.strip() == "signature value"
Exemplo n.º 6
0
 def testUsingTestData(self):
   """Test for signature_value_from_string() using test data"""
   new_signature_value = ds.signature_value_from_string(
     ds_data.TEST_SIGNATURE_VALUE)
   assert new_signature_value.id == "id"
   assert new_signature_value.text.strip() == "signature value"