Skip to content

Commit

Permalink
Fix test & imprecise assertion in test
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthiasValvekens committed Nov 21, 2023
1 parent 11fcd6b commit ddf26f8
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions pyhanko_tests/test_cms.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,7 @@
)
from pyhanko.sign.validation.generic_cms import validate_sig_integrity
from pyhanko.sign.validation.status import ClaimedAttributes
from pyhanko.sign.validation.utils import (
DEFAULT_ALGORITHM_USAGE_POLICY,
CMSAlgorithmUsagePolicy,
)
from pyhanko.sign.validation.utils import CMSAlgorithmUsagePolicy
from pyhanko_tests.samples import (
CERTOMANCER,
CRYPTO_DATA_DIR,
Expand Down Expand Up @@ -450,10 +447,9 @@ def signed_attr_providers(
timestamper=DUMMY_TS,
)
signature = cms.ContentInfo.load(signature.dump())
with pytest.raises(SignatureValidationError, match='structural'):
with pytest.raises(SignatureValidationError, match='structural.*duplicate'):
await async_validate_cms_signature(
signature['content'],
raw_digest=hashlib.sha256(b'Hello world!').digest(),
)


Expand Down

0 comments on commit ddf26f8

Please sign in to comment.