test: i dunno what youre talking about i would never leave prints in production code 🙃

Signed-off-by: Trezy <tre@trezy.com>
This commit is contained in:
Trezy
2026-08-28 20:28:54 +00:00
committed by Tangled
parent dc2f924130
commit 1866d2bf0e
+11 -19
View File
@@ -441,28 +441,20 @@ mod tests {
GrantCoverage::Withheld
);
}
}
#[cfg(test)]
mod scratch_transition_probe {
use super::*;
#[test]
fn probe() {
let g = "atproto repo:* blob:*/* rpc:* identity:* account:*?action=manage transition:generic transition:chat transition:email";
println!(
"validate mixed grant: {:?}",
ValidatedDelegationScope::new(g).is_ok()
fn test_grant_may_mix_transition_and_granular_scopes() {
assert!(ValidatedDelegationScope::new(OWNER_FULL_SCOPES).is_ok());
assert_eq!(
intersect_scopes("atproto transition:generic", OWNER_FULL_SCOPES),
"atproto transition:generic"
);
for s in ["transition:generic", "transition:chat", "transition:email"] {
println!(" {s} -> {:?}", grant_coverage(g, s));
println!(
" {s} under CURRENT owner -> {:?}",
grant_coverage(OWNER_FULL_SCOPES, s)
);
}
println!(
"intersect(transition:generic, mixed grant) = {:?}",
intersect_scopes("atproto transition:generic", g)
assert_eq!(
intersect_scopes(
"atproto repo:app.bsky.feed.post?action=create",
OWNER_FULL_SCOPES
),
"atproto repo:app.bsky.feed.post?action=create"
);
}
}