Commit graph

6 commits

Author SHA1 Message Date
Sebastian Falbesoner
c16ae71768 test: switch MiniWallet padding unit from weight to vsize
The weight unit is merely a consensus rule detail and is largely
irrelevant for fee-rate calculations and mempool policy rules (e.g. for
package relay and TRUC limits), so there doesn't seem to be any value of
using a granularity that we can't even guarantee to reach exactly
anyway.

Switch to the more natural unit of vsize instead, which simplifies both
the padding implementation and the current tests that take use of this
padding. The rather annoying multiplications by `WITNESS_SCALE_FACTOR`
can then be removed and weird-looking magic numbers like `4004` can be
replaced by numbers that are more connected to actual policy limit
constants from the codebase, e.g. `1001` for exceeding
`TRUC_CHILD_MAX_VSIZE` by one.
2024-09-28 22:49:41 +02:00
tdb3
e1d5dd732d
test: check xor.dat recreated when missing 2024-08-25 08:43:45 -04:00
tdb3
d8399584dd
refactor: move read_xor_key() to TestNode 2024-08-25 08:42:38 -04:00
tdb3
d43948c3ef
refactor: use unlink rather than os.remove 2024-08-25 08:41:21 -04:00
tdb3
c8176f758b
test: add blocks_key_path
Adds a convenience function to TestNode
to provide the path to the blocks xor key.
Updates util and feature_blocksxor to use it.
2024-08-23 12:49:56 -04:00
Sebastian Falbesoner
faa1b9b0e6 test: add functional test for XORed block/undo files (-blocksxor) 2024-08-14 17:38:28 +02:00