refactor(permission-system): simplify policy and autoreview flow

This commit is contained in:
云服务部-叶林立
2026-09-03 02:01:06 +08:00
parent 180da95ab7
commit 6e7effa792
112 changed files with 911 additions and 10346 deletions
@@ -84,7 +84,7 @@ describe("findCompiledWildcardMatch", () => {
expect(findCompiledWildcardMatch(patterns, "npm install")).toBeNull();
});
test("last-match-wins precedence: later pattern overrides earlier", () => {
test("the low-level compiled matcher returns the last matching entry", () => {
const patterns = compileWildcardPatternEntries([
["git *", "allow"],
["git push *", "deny"],
@@ -95,7 +95,7 @@ describe("findCompiledWildcardMatch", () => {
expect(result?.matchedPattern).toBe("git push *");
});
test("last-match-wins: specific deny before broad allow matches the later one", () => {
test("the low-level matcher does not apply permission-rule specificity", () => {
const patterns = compileWildcardPatternEntries([
["*", "deny"],
["git status", "allow"],