Align bundle path validation coverage
This commit is contained in:
@@ -12,6 +12,10 @@ func TestValidatePath(t *testing.T) {
|
||||
"report.md",
|
||||
"daily/report.md",
|
||||
"a-b_1.2/report.html",
|
||||
"manifest.json",
|
||||
StateFileName,
|
||||
"nested/manifest.json",
|
||||
"nested/" + StateFileName,
|
||||
}
|
||||
for _, path := range valid {
|
||||
t.Run("valid "+path, func(t *testing.T) {
|
||||
@@ -23,10 +27,14 @@ func TestValidatePath(t *testing.T) {
|
||||
|
||||
invalid := []string{
|
||||
"",
|
||||
".",
|
||||
"./report.md",
|
||||
"/absolute",
|
||||
"../outside",
|
||||
"nested/../outside",
|
||||
"nested/.",
|
||||
"nested/./file",
|
||||
"nested/",
|
||||
"nested//file",
|
||||
`nested\file`,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user