(t *testing.T)
| 23 | } |
| 24 | |
| 25 | func TestChunkIsZero(t *testing.T) { |
| 26 | t.Parallel() |
| 27 | var c Chunk |
| 28 | if !c.IsZero() { |
| 29 | t.Errorf("zero Chunk reported non-zero") |
| 30 | } |
| 31 | c.Bytes = []byte("x") |
| 32 | if c.IsZero() { |
| 33 | t.Errorf("Chunk with bytes reported zero") |
| 34 | } |
| 35 | c = Chunk{ReadAt: time.Now()} |
| 36 | if c.IsZero() { |
| 37 | t.Errorf("Chunk with ReadAt reported zero") |
| 38 | } |
| 39 | } |