mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-07-01 19:10:59 +02:00
itest+routing: updating tests to account for BlockPadding
This commit is contained in:
@ -19,8 +19,8 @@ func TestRequestRoute(t *testing.T) {
|
||||
error) {
|
||||
|
||||
// We expect find path to receive a cltv limit excluding the
|
||||
// final cltv delta.
|
||||
if *r.CltvLimit != 22 {
|
||||
// final cltv delta (including the block padding).
|
||||
if *r.CltvLimit != 22-uint32(BlockPadding) {
|
||||
t.Fatal("wrong cltv limit")
|
||||
}
|
||||
|
||||
@ -59,7 +59,8 @@ func TestRequestRoute(t *testing.T) {
|
||||
}
|
||||
|
||||
// We expect an absolute route lock value of height + finalCltvDelta
|
||||
if route.TotalTimeLock != 18 {
|
||||
// + BlockPadding.
|
||||
if route.TotalTimeLock != 18+uint32(BlockPadding) {
|
||||
t.Fatalf("unexpected total time lock of %v",
|
||||
route.TotalTimeLock)
|
||||
}
|
||||
|
Reference in New Issue
Block a user