public void TestWireDecodeTransaction() { var actual = DataDecoder.DecodeTransaction(null, TRANSACTION_1_BYTES.ToArray()); var actualBytes = DataEncoder.EncodeTransaction(actual).TxBytes; CollectionAssert.AreEqual(TRANSACTION_1_BYTES.ToList(), actualBytes.ToList()); }
public EncodedTx(UInt256 hash, ImmutableArray <byte> txBytes) { Hash = hash; TxBytes = txBytes; lazyTx = new Lazy <Transaction>(() => DataDecoder.DecodeTransaction(hash, txBytes.ToArray())); }