From 080790d84eb64504406e8f4d309e9049bdfa89ad Mon Sep 17 00:00:00 2001 From: Adrian Duke Date: Fri, 1 May 2026 16:30:26 +0100 Subject: [PATCH] radicle/git/canonical: Add explicit test case for fast_glob pattern match syntax --- crates/radicle/src/git/canonical/rules/test.rs | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/crates/radicle/src/git/canonical/rules/test.rs b/crates/radicle/src/git/canonical/rules/test.rs index 0e45d32d..07887b11 100644 --- a/crates/radicle/src/git/canonical/rules/test.rs +++ b/crates/radicle/src/git/canonical/rules/test.rs @@ -551,3 +551,14 @@ fn matches_expands_globs_appropriately() { &git::fmt::qualified!("refs/heads/quarterly/hardened/15-stable/main/2026q2") )); } + +#[test] +fn matches_exactly_curly_braces() { + let exact = qualified_pattern!("refs/heads/{foo,bar}"); + assert!(matches( + &exact, + &git::fmt::qualified!("refs/heads/{foo,bar}") + )); + assert!(!matches(&exact, &git::fmt::qualified!("refs/heads/foo"))); + assert!(!matches(&exact, &git::fmt::qualified!("refs/heads/bar"))); +}