MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / TestFileList_UpgradeV3

Function TestFileList_UpgradeV3

internal/caches/list_file_sqlite_test.go:400–426  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

398}
399
400func TestFileList_UpgradeV3(t *testing.T) {
401 if !testutils.IsSingleTesting() {
402 return
403 }
404
405 var list = caches.NewSQLiteFileList(Tea.Root + "/data/cache-index/p43").(*caches.SQLiteFileList)
406
407 defer func() {
408 _ = list.Close()
409 }()
410
411 err := list.Init()
412 if err != nil {
413 t.Fatal(err)
414 }
415
416 defer func() {
417 _ = list.Close()
418 }()
419
420 err = list.UpgradeV3("/Users/WorkSpace/EdgeProject/EdgeCache/p43", false)
421 if err != nil {
422 t.Log(err)
423 return
424 }
425 t.Log("ok")
426}
427
428func BenchmarkFileList_Exist(b *testing.B) {
429 if !testutils.IsSingleTesting() {

Callers

nothing calls this directly

Calls 6

IsSingleTestingFunction · 0.92
NewSQLiteFileListFunction · 0.92
UpgradeV3Method · 0.80
LogMethod · 0.80
CloseMethod · 0.65
InitMethod · 0.65

Tested by

no test coverage detected