(value: unknown)
| 106 | const validRefreshBody = { access_token: "tok2", token_type: "Bearer", expires_in: 3600 }; |
| 107 | |
| 108 | const jwtPart = (value: unknown): string => |
| 109 | Buffer.from(JSON.stringify(value)).toString("base64url"); |
| 110 | |
| 111 | const unsignedJwt = (claims: Record<string, unknown>, alg = "RS256"): string => |
| 112 | `${jwtPart({ alg, typ: "JWT" })}.${jwtPart(claims)}.sig`; |