Nx
Enterprise
Nx
fix(core): correct glob pattern expansion for ZeroOrOne groups The Rust hasher was incorrectly expanding glob patterns with optional groups like `__test?(s)__` because ZeroOrOne and ZeroOrMore patterns were combined in the same match arm but require different handling. The issue was that ZeroOrOne patterns were using `*` as a fallback when not matched, which caused patterns like `__test?(s)__` to incorrectly expand to `*__` instead of `__test__` when the optional `s` was not matched. This fix separates the ZeroOrOne and ZeroOrMore cases, ensuring that ZeroOrOne patterns preserve the existing pattern when the optional group is not matched. Fixes #26880 Co-authored-by: Craigory Coppola <AgentEnder@users.noreply.github.com> test(native): add unit tests for ZeroOrOne glob pattern behavior Add comprehensive unit tests for ZeroOrOne pattern expansion to verify the fix for issue #26880 where patterns like `__test?(s)__` were incorrectly expanding to `*__` instead of `__test__`. The tests cover: - Simple ZeroOrOne pattern: `__test?(s)__` - Pattern with prefix: `prefix?(suffix)` - Pattern in middle: `start?(middle)end` - Multiple ZeroOrOne patterns: `?(a)test?(b)` Co-authored-by: Craigory Coppola <AgentEnder@users.noreply.github.com> style(native): format Rust code with rustfmt Apply rustfmt formatting to the glob_transform.rs file to ensure consistent code style after adding the new unit tests. Co-authored-by: Craigory Coppola <AgentEnder@users.noreply.github.com>
nx documentation
Sign in / Sign up
Open main menu
Succeeded
CI Pipeline Execution
1 run failed
nx documentation
Click to copy
2536271e
31857
38%
Cache hits
5 of 13 tasks used cache.