(t *testing.T)
| 486 | } |
| 487 | |
| 488 | func TestFileStorage_Delete(t *testing.T) { |
| 489 | if !testutils.IsSingleTesting() { |
| 490 | return |
| 491 | } |
| 492 | |
| 493 | var storage = NewFileStorage(&serverconfigs.HTTPCachePolicy{ |
| 494 | Id: 1, |
| 495 | IsOn: true, |
| 496 | Options: map[string]interface{}{ |
| 497 | "dir": Tea.Root + "/caches", |
| 498 | }, |
| 499 | }) |
| 500 | |
| 501 | defer storage.Stop() |
| 502 | |
| 503 | err := storage.Init() |
| 504 | if err != nil { |
| 505 | t.Fatal(err) |
| 506 | } |
| 507 | err = storage.Delete("my-key") |
| 508 | if err != nil { |
| 509 | t.Fatal(err) |
| 510 | } |
| 511 | t.Log("ok") |
| 512 | } |
| 513 | |
| 514 | func TestFileStorage_Stat(t *testing.T) { |
| 515 | if !testutils.IsSingleTesting() { |
nothing calls this directly
no test coverage detected