mirror of
https://github.com/octoleo/restic.git
synced 2024-11-25 14:17:42 +00:00
Merge pull request #4450 from MichaelEischer/cleanup-master-index-test
master_index: fix inconsistent length blob length in test
This commit is contained in:
commit
6e586b64e4
@ -46,6 +46,7 @@ func TestMasterIndex(t *testing.T) {
|
|||||||
BlobHandle: bhInIdx12,
|
BlobHandle: bhInIdx12,
|
||||||
Length: uint(crypto.CiphertextLength(123)),
|
Length: uint(crypto.CiphertextLength(123)),
|
||||||
Offset: 110,
|
Offset: 110,
|
||||||
|
UncompressedLength: 80,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -116,7 +117,7 @@ func TestMasterIndex(t *testing.T) {
|
|||||||
|
|
||||||
size, found = mIdx.LookupSize(bhInIdx12)
|
size, found = mIdx.LookupSize(bhInIdx12)
|
||||||
rtest.Equals(t, true, found)
|
rtest.Equals(t, true, found)
|
||||||
rtest.Equals(t, uint(123), size)
|
rtest.Equals(t, uint(80), size)
|
||||||
|
|
||||||
// test not in index
|
// test not in index
|
||||||
found = mIdx.Has(restic.BlobHandle{ID: restic.NewRandomID(), Type: restic.TreeBlob})
|
found = mIdx.Has(restic.BlobHandle{ID: restic.NewRandomID(), Type: restic.TreeBlob})
|
||||||
|
Loading…
Reference in New Issue
Block a user