Exemple #1
0
 def test_v1_2_signed_multiple_signers(self):
     with open(
             '../examples/1.2/sample_signed_cert_multiple_signers-1.2.json'
     ) as data_f:
         certificate = json.load(data_f)
         valid = validate_v1_2(certificate)
         self.assertTrue(valid)
Exemple #2
0
 def test_v1_2_invalid(self):
     with open('../examples/1.2/sample_invalid_cert-1.2.json') as data_f:
         certificate = json.load(data_f)
         try:
             valid = validate_v1_2(certificate)
         except BlockcertValidationError as bve:
             self.assertTrue(True, 'Got validation error, as expected')
             return
     self.fail('Did not get expected validation error')