mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 15:16:43 +00:00
cmd/geth: Fix type mismatches in dbcmd_test.go between uint64 and int
This commit is contained in:
parent
6942807df3
commit
39765c1d92
1 changed files with 3 additions and 3 deletions
|
|
@ -180,15 +180,15 @@ func TestTruncateFreezerBatching(t *testing.T) {
|
||||||
// or the number of items in the original freezer, whichever is smaller
|
// or the number of items in the original freezer, whichever is smaller
|
||||||
expectedCount := mergeBlock
|
expectedCount := mergeBlock
|
||||||
if ancients < mergeBlock {
|
if ancients < mergeBlock {
|
||||||
expectedCount = ancients
|
expectedCount = int(ancients)
|
||||||
}
|
}
|
||||||
|
|
||||||
if headersFreezerAncients != expectedCount {
|
if int(headersFreezerAncients) != expectedCount {
|
||||||
t.Fatalf("Expected %d items in headers freezer, got %d", expectedCount, headersFreezerAncients)
|
t.Fatalf("Expected %d items in headers freezer, got %d", expectedCount, headersFreezerAncients)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Verify that the headers in the temporary freezer match the originals
|
// Verify that the headers in the temporary freezer match the originals
|
||||||
for i := uint64(0); i < expectedCount; i++ {
|
for i := uint64(0); i < uint64(expectedCount); i++ {
|
||||||
// Read from original freezer
|
// Read from original freezer
|
||||||
originalHeader, err := ancientDb.Ancient(rawdb.ChainFreezerHeaderTable, i)
|
originalHeader, err := ancientDb.Ancient(rawdb.ChainFreezerHeaderTable, i)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue