Skip to content

Commit 65c5c30

Browse files
committed
cover both binary seralization
1 parent abaec44 commit 65c5c30

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/script/__tests/Spend.test.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -432,5 +432,13 @@ describe('Spend', () => {
432432
const valid = await spendTx.verify(chain)
433433

434434
expect(valid).toBe(true)
435+
436+
const b = spendTx.toBinary()
437+
const t = Transaction.fromBinary(b)
438+
expect(t.inputs[0].sequence).toBe(0xffffffff)
439+
440+
const b2 = spendTx.toEF()
441+
const t2 = Transaction.fromEF(b2)
442+
expect(t2.inputs[0].sequence).toBe(0xffffffff)
435443
})
436444
})

0 commit comments

Comments
 (0)