fix: opt the audit probe token into superadmin (#12710)

Since new tokens carry superadmin only when minted asking for it, the
nonmember superadmin's token ran as a plain user and could not run the
g/all-shared on-behalf script.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Ruben Fiszel
2026-11-27 17:31:57 +01:00
committed by GitHub
co-authored by Claude Opus 5.5
parent 48207eafdb
commit 3ad867ee65
@@ -66,7 +66,7 @@ async fn test_job_run_is_searchable_by_token_and_by_caller(
let port = server.addr.port();
let resp = authed(client().post(format!("http://localhost:{port}/api/users/tokens/create")))
.json(&json!({ "label": "audit-probe" }))
.json(&json!({ "label": "audit-probe", "super_admin": true }))
.send()
.await?;
assert_eq!(resp.status(), 201);