(t *testing.T)
| 235 | } |
| 236 | |
| 237 | func TestStorageManager_DownloadAllMeta(t *testing.T) { |
| 238 | setup(t) |
| 239 | err := storageManager.DownloadAllMetas(context.Background(), 4) |
| 240 | if err != nil { |
| 241 | t.Fatal("failed to Downloand Finished", err) |
| 242 | } |
| 243 | |
| 244 | kvIndex := uint64(3) |
| 245 | _, h := createBlob(kvIndex) |
| 246 | bs, success, err := storageManager.TryReadMeta(kvIndex) |
| 247 | if err != nil || !success { |
| 248 | t.Fatal("failed to read meta", err) |
| 249 | } |
| 250 | |
| 251 | meta := common.Hash{} |
| 252 | copy(meta[:], bs) |
| 253 | if meta != PrepareCommit(h) { |
| 254 | t.Fatal("failed to compare meta", err) |
| 255 | } |
| 256 | } |
nothing calls this directly
no test coverage detected