core/rawdb: fix comparison in test

This commit is contained in:
Felix Lange 2025-03-19 09:07:02 +01:00
parent a20cdbc6f9
commit 36cb9a7d6d

View file

@ -245,7 +245,7 @@ func TestPruneTransactionIndex(t *testing.T) {
if block.NumberU64() < pruneBlock && num != nil {
t.Fatalf("TxLookup entry not removed: %x -> %v", tx.Hash(), num)
}
if block.NumberU64() > pruneBlock && (num == nil || *num != block.NumberU64()) {
if block.NumberU64() >= pruneBlock && (num == nil || *num != block.NumberU64()) {
t.Fatalf("wrong TxLookup entry after pruning: %x -> %v", tx.Hash(), num)
}
}