(t *testing.T)
| 155 | } |
| 156 | |
| 157 | func TestInValidNonRecursiveFilePatterns(t *testing.T) { |
| 158 | t.Parallel() |
| 159 | |
| 160 | data := []struct { |
| 161 | pattern string |
| 162 | dir string |
| 163 | }{ |
| 164 | {"/path/*.txt", "/path/file.php"}, |
| 165 | {"/path/*.php", "/path/subpath/file.php"}, |
| 166 | {"/*.php", "/path/file.php"}, |
| 167 | {"*.txt", relativeDir(t, "file.php")}, |
| 168 | {"*.php", relativeDir(t, "subpath/file.php")}, |
| 169 | } |
| 170 | |
| 171 | for _, d := range data { |
| 172 | t.Run(d.pattern, func(t *testing.T) { |
| 173 | t.Parallel() |
| 174 | |
| 175 | assertPatternNotMatch(t, d.pattern, d.dir) |
| 176 | }) |
| 177 | } |
| 178 | } |
| 179 | |
| 180 | func TestValidRecursiveFilePatterns(t *testing.T) { |
| 181 | t.Parallel() |
nothing calls this directly
no test coverage detected