MCPcopy
hub / github.com/cubefs/cubefs / testDeleteDirTree

Function testDeleteDirTree

metanode/multi_ver_test.go:930–941  ·  view source on GitHub ↗
(t *testing.T, parentId uint64, verSeq uint64)

Source from the content-addressed store, hash-verified

928}
929
930func testDeleteDirTree(t *testing.T, parentId uint64, verSeq uint64) {
931 t.Logf("testDeleteDirTree parentId %v seq [%v]", parentId, verSeq)
932 rspReadDir := testReadDirAll(t, verSeq, parentId)
933 for _, child := range rspReadDir.Children {
934 if proto.IsDir(child.Type) {
935 testDeleteDirTree(t, child.Inode, verSeq)
936 }
937 t.Logf("action[testDeleteDirTree] delete children %v", child)
938 log.LogDebugf("action[testDeleteDirTree] seq [%v] delete children %v", verSeq, child)
939 testDeleteFile(t, verSeq, parentId, &child)
940 }
941}
942
943func testCleanSnapshot(t *testing.T, verSeq uint64) {
944 t.Logf("action[testCleanSnapshot] verseq [%v]", verSeq)

Callers 2

testCleanSnapshotFunction · 0.85
testSnapshotDeletionFunction · 0.85

Calls 4

IsDirFunction · 0.92
LogDebugfFunction · 0.92
testReadDirAllFunction · 0.85
testDeleteFileFunction · 0.85

Tested by

no test coverage detected