Test the branch patterns work both ways

This commit is contained in:
Simon Engledew
2020-12-01 17:16:33 +00:00
parent f99af1c014
commit b1be00db57
6 changed files with 24 additions and 13 deletions
+2
View File
@@ -223,6 +223,8 @@ ava_1.default("patternsOverlap()", (t) => {
t.false(actionsutil.patternsOverlap("*", "feature/*"));
t.true(actionsutil.patternsOverlap("**", "feature/*"));
t.false(actionsutil.patternsOverlap("feature-*", "**"));
t.false(actionsutil.patternsOverlap("a/**/c", "a/**/d"));
t.false(actionsutil.patternsOverlap("a/**/c", "a/**"));
t.true(actionsutil.patternsOverlap("/robin/*/release/*", "/robin/moose/release/goose"));
t.false(actionsutil.patternsOverlap("/robin/moose/release/goose", "/robin/*/release/*"));
});