ACM-PCA: Use serialisable types instead of native objs
This is a follow up to https://github.com/getmoto/moto/pull/7958
The ImportCertificateAuthorityCertificate would create a cryptography.hazmat.bindings._rust.x509.Certificate object as assign it as a CertificateAuthority class member. This prevents it from being serialised with pickle.
This PR reworks the certificate and private key attributes so that all members are picklable.
Hey @viren-nadkarni! Do you want to add some tests for this as well in Moto? Just to prevent it from breaking again in the future
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 94.43%. Comparing base (
191ebcc) to head (ecfa1b3). Report is 7 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #8039 +/- ##
=======================================
Coverage 94.43% 94.43%
=======================================
Files 1139 1139
Lines 97355 97387 +32
=======================================
+ Hits 91935 91966 +31
- Misses 5420 5421 +1
| Flag | Coverage Δ | |
|---|---|---|
| servertests | 28.98% <36.36%> (+0.05%) |
:arrow_up: |
| unittests | 94.40% <100.00%> (+<0.01%) |
:arrow_up: |
Flags with carried forward coverage won't be shown. Click here to find out more.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.