MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / creds_fail_when_keypair_cannot_load

Function creds_fail_when_keypair_cannot_load

atomic-cli/src/commands/auth.rs:550–566  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

548
549 #[test]
550 fn creds_fail_when_keypair_cannot_load() {
551 // Identity exists but its signing key can't be loaded — no token can be
552 // minted. This stands in for an "expired"/unusable credential, which in
553 // this self-signed-JWT model means "cannot sign right now".
554 let issue = evaluate_push_credentials(
555 Some("alice".to_string()),
556 false,
557 |_| true, // identity exists
558 |_| false, // keypair unavailable
559 );
560 assert_eq!(
561 issue,
562 Some(CredentialIssue::KeypairUnavailable {
563 name: "alice".to_string()
564 })
565 );
566 }
567
568 #[test]
569 fn credential_issue_messages_are_actionable() {

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected