MCPcopy Index your code
hub / github.com/git-lfs/git-lfs / TestNewDirWalkerForFile

Function TestNewDirWalkerForFile

tools/dir_walker_test.go:23–35  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

21}
22
23func TestNewDirWalkerForFile(t *testing.T) {
24 for desc, c := range map[string]*newDirWalkerForFileTestCase{
25 "filename only": {"foo.bin", ""},
26 "path with one dir": {"abc/foo.bin", "abc"},
27 "path with two dirs": {"abc/def/foo.bin", "abc/def"},
28 "path with leading slash": {"/foo.bin", ""},
29 "path with trailing slash": {"abc/", "abc"},
30 "bare slash": {"/", ""},
31 "empty path": {"", ""},
32 } {
33 t.Run(desc, c.Assert)
34 }
35}
36
37type dirWalkerTestConfig struct{}
38

Callers

nothing calls this directly

Calls 1

RunMethod · 0.65

Tested by

no test coverage detected