bynk.test.forged_needs_system
Error A case drives by Forged, by Stale, by Expired, by WrongIssuer, by WrongAudience, by WrongAlgorithm or by NoSubject outside a system-tier case; only the system driver signs a request or mints a token, so only there does the real Signature, Bearer or Oidc seam see the bad credential.
by Forged, by Stale and the other bad-credential principals send a forged or out-of-date credential to the real auth seam, which only a system case reaches. In process the seam is skipped and the identity is simply given, so there is nothing to refuse. Move the case to system with as system.
Example
case "a forged token is refused" { // ✗ not a system casecase "a forged token is refused" as system { // ✓ let r <- api.GET("/a") by Forged expect r is Rejected(Unauthorized)}In the Book
See also
- The grammar rule it governs:
case. - Every code in its category, Tests, on the diagnostic index.
bynk explain bynk.test.forged_needs_systemshows the same from the installed toolchain, without a network.