test(pq-key-fingerprint/ts): phase 4 - comprehensive test coverage (ENG-1763)#25
Merged
test(pq-key-fingerprint/ts): phase 4 - comprehensive test coverage (ENG-1763)#25
Conversation
This was referenced Mar 4, 2026
Member
Author
7 tasks
Greptile SummaryThis PR adds phase 4 comprehensive test coverage for the Key changes:
Notable observations:
Confidence Score: 4/5
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
subgraph Inputs["Test Inputs"]
A["VECTOR_BYTES\n(bytes 0x00–0x1F)"]
B["ml_kem_512_pub.der\n(SPKI/DER fixture)"]
C["ml_kem_512_pub.pem\n(PEM fixture)"]
end
subgraph Entrypoints["Public API Entrypoints"]
E1["fingerprintPublicKeyBytes()"]
E2["fingerprintPublicKey()"]
E3["fingerprintSPKI()"]
E4["fingerprintPEM()"]
E5["fingerprintJWK()"]
end
subgraph Internal["Internal Pipeline"]
N1["normalizePublicKeyInput()"]
N2["fromSPKI() — pq-key-encoder"]
N3["fromPEM() — pq-key-encoder"]
N4["fromJWK() — pq-key-encoder"]
N5["ensurePublicKeyData()"]
N6["digestBytes() — WebCrypto subtle.digest"]
N7["encodeFingerprint()"]
end
subgraph Outputs["Fingerprint Result"]
R1["hex string (default)"]
R2["base64 string"]
R3["base64url string"]
R4["Uint8Array bytes"]
end
subgraph Errors["Error Boundary — withErrorBoundary()"]
ERR1["InvalidKeyTypeError"]
ERR2["InvalidFingerprintInputError"]
ERR3["UnsupportedDigestError"]
ERR4["RuntimeCapabilityError"]
end
A --> E1 & E2
B --> E3
C --> E4
B -->|toJWK| E5
E1 --> N1
E2 --> N1
E3 --> N2 --> N5
E4 --> N3 --> N5
E5 --> N4 --> N5
N1 --> N5
N5 --> N6 --> N7 --> R1 & R2 & R3 & R4
N5 -->|private key| ERR1
N1 -->|invalid input| ERR2
N6 -->|no WebCrypto| ERR4
N7 -->|bad digest| ERR3
Last reviewed commit: c691db3 |
Member
Author
|
@codex review |
|
Codex Review: Didn't find any major issues. Keep it up! ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Amp-Thread-ID: https://ampcode.com/threads/T-019cd729-94be-7449-aaf9-90c18e3de13a Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-019cd850-0f5f-723d-bbeb-9522c0aa67bf Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-019cd868-2b8b-756b-b9dd-d0244b9e1aa0 Co-authored-by: Amp <amp@ampcode.com>
Amp-Thread-ID: https://ampcode.com/threads/T-019cd872-e9a0-7597-829a-36b5522c012d Co-authored-by: Amp <amp@ampcode.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Package(s)
Languages
Checklist
biome check,cargo fmt)Related Issues