Add StringTitle
This commit is contained in:
22
file_test.go
Normal file
22
file_test.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package commons
|
||||
|
||||
import (
|
||||
"testing"
|
||||
"slices"
|
||||
)
|
||||
|
||||
func TestFileDeepScan(t *testing.T) {
|
||||
files := make([]string, 0)
|
||||
|
||||
FileDeepScan(".file", &files)
|
||||
|
||||
l := len(files)
|
||||
|
||||
if l != 2 {
|
||||
t.Fatalf("Should have found %d files", l)
|
||||
}
|
||||
|
||||
if !slices.Contains(files, ".file/dir1/file1.json") {
|
||||
t.Fatal("Should have found file1.json")
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user