Skip to content

Commit

Permalink
Merge pull request #18 from iotaledger/core-node/fix/remove-hash_publ…
Browse files Browse the repository at this point in the history
…ic_transfer

Remove deprecated flag `has_public_transfer`
  • Loading branch information
Thoralf-M authored Nov 8, 2024
2 parents 66df4b7 + d59017a commit 8c849de
Show file tree
Hide file tree
Showing 10 changed files with 197 additions and 72 deletions.
80 changes: 32 additions & 48 deletions crates/iota-rust-sdk/src/types/object.rs
Original file line number Diff line number Diff line change
Expand Up @@ -190,10 +190,6 @@ pub struct MoveStruct {
serde(with = "::serde_with::As::<serialization::BinaryMoveStructType>")
)]
pub type_: StructTag,
/// DEPRECATED this field is no longer used to determine whether a tx can
/// transfer this object. Instead, it is always calculated from the
/// objects type when loaded in execution
pub has_public_transfer: bool,
/// Number that increases each time a tx takes this object as a mutable
/// input This is a lamport timestamp, not a sequentially increasing
/// version
Expand Down Expand Up @@ -321,7 +317,6 @@ mod serialization {
name: Identifier::new("foo").unwrap(),
type_params: Vec::new(),
},
has_public_transfer: true,
version: 12,
contents: ObjectId::ZERO.into(),
}),
Expand Down Expand Up @@ -564,7 +559,6 @@ mod serialization {
schemars(rename = "MoveStruct")
)]
struct ReadableMoveStruct {
has_public_transfer: bool,
#[serde(with = "::serde_with::As::<crate::_serde::Base64Encoded>")]
#[cfg_attr(feature = "schemars", schemars(with = "crate::_schemars::Base64"))]
contents: Vec<u8>,
Expand All @@ -574,7 +568,6 @@ mod serialization {
fn readable_object_data(&self) -> ReadableObjectData {
match &self.data {
ObjectData::Struct(struct_) => ReadableObjectData::Move(ReadableMoveStruct {
has_public_transfer: struct_.has_public_transfer,
contents: struct_.contents.clone(),
}),
ObjectData::Package(package) => ReadableObjectData::Package(ReadablePackage {
Expand Down Expand Up @@ -649,10 +642,7 @@ mod serialization {
}),
(
ObjectType::Struct(type_),
ReadableObjectData::Move(ReadableMoveStruct {
has_public_transfer,
contents,
}),
ReadableObjectData::Move(ReadableMoveStruct { contents }),
) => {
// check id matches in contents
if !id_opt(&contents).is_some_and(|id| id == object_id) {
Expand All @@ -661,7 +651,6 @@ mod serialization {

ObjectData::Struct(MoveStruct {
type_,
has_public_transfer,
version,
contents,
})
Expand Down Expand Up @@ -740,7 +729,6 @@ mod serialization {
fn readable_object_data(&self) -> ReadableObjectData {
match &self.data {
ObjectData::Struct(struct_) => ReadableObjectData::Move(ReadableMoveStruct {
has_public_transfer: struct_.has_public_transfer,
contents: struct_.contents.clone(),
}),
ObjectData::Package(package) => ReadableObjectData::Package(ReadablePackage {
Expand Down Expand Up @@ -808,10 +796,7 @@ mod serialization {
}),
(
ObjectType::Struct(type_),
ReadableObjectData::Move(ReadableMoveStruct {
has_public_transfer,
contents,
}),
ReadableObjectData::Move(ReadableMoveStruct { contents }),
) => {
// check id matches in contents
if !id_opt(&contents).is_some_and(|id| id == object_id) {
Expand All @@ -820,7 +805,6 @@ mod serialization {

ObjectData::Struct(MoveStruct {
type_,
has_public_transfer,
version,
contents,
})
Expand Down Expand Up @@ -848,50 +832,50 @@ mod serialization {
#[test]
fn object_fixture() {
const IOTA_COIN: &[u8] = &[
0, 1, 1, 32, 79, 43, 0, 0, 0, 0, 0, 40, 35, 95, 175, 213, 151, 87, 206, 190, 35,
131, 79, 35, 254, 22, 15, 181, 40, 108, 28, 77, 68, 229, 107, 254, 191, 160, 196,
186, 42, 2, 122, 53, 52, 133, 199, 58, 0, 0, 0, 0, 0, 79, 255, 208, 0, 85, 34, 190,
75, 192, 41, 114, 76, 127, 15, 110, 215, 9, 58, 107, 243, 160, 155, 144, 230, 47,
97, 220, 21, 24, 30, 26, 62, 32, 17, 197, 192, 38, 64, 173, 142, 143, 49, 111, 15,
211, 92, 84, 48, 160, 243, 102, 229, 253, 251, 137, 210, 101, 119, 173, 228, 51,
141, 20, 15, 85, 96, 19, 15, 0, 0, 0, 0, 0,
0, 1, 32, 79, 43, 0, 0, 0, 0, 0, 40, 35, 95, 175, 213, 151, 87, 206, 190, 35, 131,
79, 35, 254, 22, 15, 181, 40, 108, 28, 77, 68, 229, 107, 254, 191, 160, 196, 186,
42, 2, 122, 53, 52, 133, 199, 58, 0, 0, 0, 0, 0, 79, 255, 208, 0, 85, 34, 190, 75,
192, 41, 114, 76, 127, 15, 110, 215, 9, 58, 107, 243, 160, 155, 144, 230, 47, 97,
220, 21, 24, 30, 26, 62, 32, 17, 197, 192, 38, 64, 173, 142, 143, 49, 111, 15, 211,
92, 84, 48, 160, 243, 102, 229, 253, 251, 137, 210, 101, 119, 173, 228, 51, 141,
20, 15, 85, 96, 19, 15, 0, 0, 0, 0, 0,
];

const IOTA_STAKE: &[u8] = &[
0, 2, 1, 154, 1, 52, 5, 0, 0, 0, 0, 80, 3, 112, 71, 231, 166, 234, 205, 164, 99,
237, 29, 56, 97, 170, 21, 96, 105, 158, 227, 122, 22, 251, 60, 162, 12, 97, 151,
218, 71, 253, 231, 239, 116, 138, 12, 233, 128, 195, 128, 77, 33, 38, 122, 77, 53,
154, 197, 198, 75, 212, 12, 182, 163, 224, 42, 82, 123, 69, 248, 40, 207, 143, 211,
13, 106, 1, 0, 0, 0, 0, 0, 0, 59, 81, 183, 246, 112, 0, 0, 0, 0, 79, 255, 208, 0,
85, 34, 190, 75, 192, 41, 114, 76, 127, 15, 110, 215, 9, 58, 107, 243, 160, 155,
144, 230, 47, 97, 220, 21, 24, 30, 26, 62, 32, 247, 239, 248, 71, 247, 102, 190,
149, 232, 153, 138, 67, 169, 209, 203, 29, 255, 215, 223, 57, 159, 44, 40, 218,
166, 13, 80, 71, 14, 188, 232, 68, 0, 0, 0, 0, 0, 0, 0, 0,
0, 2, 154, 1, 52, 5, 0, 0, 0, 0, 80, 3, 112, 71, 231, 166, 234, 205, 164, 99, 237,
29, 56, 97, 170, 21, 96, 105, 158, 227, 122, 22, 251, 60, 162, 12, 97, 151, 218,
71, 253, 231, 239, 116, 138, 12, 233, 128, 195, 128, 77, 33, 38, 122, 77, 53, 154,
197, 198, 75, 212, 12, 182, 163, 224, 42, 82, 123, 69, 248, 40, 207, 143, 211, 13,
106, 1, 0, 0, 0, 0, 0, 0, 59, 81, 183, 246, 112, 0, 0, 0, 0, 79, 255, 208, 0, 85,
34, 190, 75, 192, 41, 114, 76, 127, 15, 110, 215, 9, 58, 107, 243, 160, 155, 144,
230, 47, 97, 220, 21, 24, 30, 26, 62, 32, 247, 239, 248, 71, 247, 102, 190, 149,
232, 153, 138, 67, 169, 209, 203, 29, 255, 215, 223, 57, 159, 44, 40, 218, 166, 13,
80, 71, 14, 188, 232, 68, 0, 0, 0, 0, 0, 0, 0, 0,
];

const NFT: &[u8] = &[
0, 0, 97, 201, 195, 159, 216, 97, 133, 173, 96, 215, 56, 212, 229, 43, 208, 139,
218, 7, 29, 54, 106, 205, 224, 126, 7, 195, 145, 106, 45, 117, 168, 22, 12, 100,
105, 115, 116, 114, 105, 98, 117, 116, 105, 111, 110, 11, 68, 69, 69, 80, 87, 114,
97, 112, 112, 101, 114, 0, 0, 124, 24, 223, 4, 0, 0, 0, 0, 40, 31, 8, 18, 84, 38,
164, 252, 84, 115, 250, 246, 137, 132, 128, 186, 156, 36, 62, 18, 140, 21, 4, 90,
209, 105, 85, 84, 92, 214, 97, 81, 207, 64, 194, 198, 208, 21, 0, 0, 0, 0, 79, 255,
208, 0, 85, 34, 190, 75, 192, 41, 114, 76, 127, 15, 110, 215, 9, 58, 107, 243, 160,
155, 144, 230, 47, 97, 220, 21, 24, 30, 26, 62, 32, 170, 4, 94, 114, 207, 155, 31,
80, 62, 254, 220, 206, 240, 218, 83, 54, 204, 197, 255, 239, 41, 66, 199, 150, 56,
189, 86, 217, 166, 216, 128, 241, 64, 205, 21, 0, 0, 0, 0, 0,
97, 112, 112, 101, 114, 0, 124, 24, 223, 4, 0, 0, 0, 0, 40, 31, 8, 18, 84, 38, 164,
252, 84, 115, 250, 246, 137, 132, 128, 186, 156, 36, 62, 18, 140, 21, 4, 90, 209,
105, 85, 84, 92, 214, 97, 81, 207, 64, 194, 198, 208, 21, 0, 0, 0, 0, 79, 255, 208,
0, 85, 34, 190, 75, 192, 41, 114, 76, 127, 15, 110, 215, 9, 58, 107, 243, 160, 155,
144, 230, 47, 97, 220, 21, 24, 30, 26, 62, 32, 170, 4, 94, 114, 207, 155, 31, 80,
62, 254, 220, 206, 240, 218, 83, 54, 204, 197, 255, 239, 41, 66, 199, 150, 56, 189,
86, 217, 166, 216, 128, 241, 64, 205, 21, 0, 0, 0, 0, 0,
];

const FUD_COIN: &[u8] = &[
0, 3, 7, 118, 203, 129, 155, 1, 171, 237, 80, 43, 238, 138, 112, 43, 76, 45, 84,
117, 50, 193, 47, 37, 0, 28, 157, 234, 121, 90, 94, 99, 28, 38, 241, 3, 102, 117,
100, 3, 70, 85, 68, 0, 1, 193, 89, 252, 3, 0, 0, 0, 0, 40, 33, 214, 90, 11, 56,
243, 115, 10, 250, 121, 250, 28, 34, 237, 104, 130, 148, 40, 130, 29, 248, 137,
244, 27, 138, 94, 150, 28, 182, 104, 162, 185, 0, 152, 247, 62, 93, 1, 0, 0, 0, 42,
95, 32, 226, 13, 31, 128, 91, 188, 127, 235, 12, 75, 73, 116, 112, 3, 227, 244,
126, 59, 81, 214, 118, 144, 243, 195, 17, 82, 216, 119, 170, 32, 239, 247, 71, 249,
241, 98, 133, 53, 46, 37, 100, 242, 94, 231, 241, 184, 8, 69, 192, 69, 67, 1, 116,
251, 229, 226, 99, 119, 79, 255, 71, 43, 64, 242, 19, 0, 0, 0, 0, 0,
100, 3, 70, 85, 68, 0, 193, 89, 252, 3, 0, 0, 0, 0, 40, 33, 214, 90, 11, 56, 243,
115, 10, 250, 121, 250, 28, 34, 237, 104, 130, 148, 40, 130, 29, 248, 137, 244, 27,
138, 94, 150, 28, 182, 104, 162, 185, 0, 152, 247, 62, 93, 1, 0, 0, 0, 42, 95, 32,
226, 13, 31, 128, 91, 188, 127, 235, 12, 75, 73, 116, 112, 3, 227, 244, 126, 59,
81, 214, 118, 144, 243, 195, 17, 82, 216, 119, 170, 32, 239, 247, 71, 249, 241, 98,
133, 53, 46, 37, 100, 242, 94, 231, 241, 184, 8, 69, 192, 69, 67, 1, 116, 251, 229,
226, 99, 119, 79, 255, 71, 43, 64, 242, 19, 0, 0, 0, 0, 0,
];

const BULLSHARK_PACKAGE: &[u8] = &[
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
AAQBAAEAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADCvRQiTAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAA
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
AAIAAAAAAAAAAAMAAAAAAAAAAPSuRQiTAQAAIMqkGXCaiwgO7vW+HxGGRJKqK/XG/PDv0XQvYDPtrP9BAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAA==

Large diffs are not rendered by default.

This file was deleted.

1 change: 1 addition & 0 deletions crates/iota-rust-sdk/src/types/transaction/fixtures/ptb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
AAACAQBd73FNj10Qajf+57GswFchYNMadHool5oWwooqv2OsHQEAAAAAAAAAIMywMsW0Eq8kxUMvPriunI4/5MFevTlujsluEO2eq3sBAAkBQEIPAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACA3BheQlzcGxpdF92ZWMBBwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACBGlvdGEESU9UQQACAQAAAQEAD3roDxNW8al/e8qSMX1VsrnQKhFCf2d00KrpSeBUxd4BX2H7GBo8Dz687+cs2Zz0jgm7eTVBr9REodZ6XRGb9GcBAAAAAAAAACBUwR888cuuNQritn9jaBy8dbKeUZ0CwB8kRLqKHQMgig966A8TVvGpf3vKkjF9VbK50CoRQn9ndNCq6UngVMXe6AMAAAAAAABAQg8AAAAAAAA=
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/target
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
[workspace]

[package]
name = "update_transaction_fixtures"
version = "0.1.0"
edition = "2021"

[dependencies]
anyhow = "1.0.71"
bcs = "0.1.4"
fastcrypto = { git = "https://github.com/MystenLabs/fastcrypto", rev = "5f2c63266a065996d53f98156f0412782b468597" }
iota-json-rpc-types = { path = "../../../../../../../../iota/crates/iota-json-rpc-types" }
iota-sdk = { path = "../../../../../../../../iota/crates/iota-sdk" }
iota-keys = { path = "../../../../../../../../iota/crates/iota-keys" }
iota-types = { path = "../../../../../../../../iota/crates/iota-types" }
test-cluster = { path = "../../../../../../../../iota/crates/test-cluster" }
tokio = "1.39.2"
futures = "0.3.28"
Original file line number Diff line number Diff line change
@@ -0,0 +1,137 @@
// Copyright (c) 2024 IOTA Stiftung
// SPDX-License-Identifier: Apache-2.0

//! Update the fixtures for the transaction_fixtures() test.
//! For this to work, have the `iota` repo next to `iota-rust-sdk` and in
//! the iota repo checkout to the branch for which the fixtures should be
//! created.
//!
//! cargo run

use std::{fs::OpenOptions, io::Write};

use fastcrypto::encoding::{Base64, Encoding};
use futures::StreamExt;
use iota_json_rpc_types::{
IotaEndOfEpochTransactionKind, IotaTransactionBlockDataAPI, IotaTransactionBlockKind,
IotaTransactionBlockResponseOptions, IotaTransactionBlockResponseQuery,
};
use iota_types::transaction::SenderSignedData;
use test_cluster::TestClusterBuilder;

const BASE_PATH: &str = "../";

#[tokio::main]
async fn main() -> Result<(), anyhow::Error> {
let test_cluster = TestClusterBuilder::new().build().await;
let client = test_cluster.wallet.get_client().await?;

// Build a PTB
let address = test_cluster.get_address_0();
let object_refs = client
.read_api()
.get_owned_objects(address, None, None, None)
.await?;
let gas_coin = object_refs.data.first().unwrap().object()?.object_id;
let ptb_tx_data = client
.transaction_builder()
.split_coin(address, gas_coin, vec![1_000_000], None, 1_000_000)
.await?;
write_bs64_tx_to_file(&bcs::to_bytes(&ptb_tx_data)?, "ptb")?;

// Force new epoch so we get a change epoch tx
test_cluster.force_new_epoch().await;

let mut txs = client
.read_api()
.get_transactions_stream(
IotaTransactionBlockResponseQuery::new(
None,
Some(
IotaTransactionBlockResponseOptions::new()
.with_raw_input()
.with_input(),
),
),
None,
// Starts with the genesis tx
false,
)
.boxed();

let mut got_consensus_commit_prologue_v1 = false;
let mut got_epoch_change = false;
let mut got_genesis = false;

while let Some(tx) = txs.next().await {
let transaction = tx.transaction.as_ref().expect(
"Missing tx in response, add .with_input() to IotaTransactionBlockResponseOptions",
);
match transaction.data.transaction() {
IotaTransactionBlockKind::Genesis(_genesis_transaction) => {
if !got_genesis {
write_bs64_tx_to_file(
&raw_tx_bytes_to_transaction_data_bytes(&tx.raw_transaction)?,
"genesis",
)?;
got_genesis = true;
}
}
IotaTransactionBlockKind::ConsensusCommitPrologueV1(_consensus_commit_prologue) => {
if !got_consensus_commit_prologue_v1 {
write_bs64_tx_to_file(
&raw_tx_bytes_to_transaction_data_bytes(&tx.raw_transaction)?,
"consensus-commit-prologue-v1",
)?;
got_consensus_commit_prologue_v1 = true;
}
}
IotaTransactionBlockKind::EndOfEpochTransaction(end_of_epoch_tx) => {
for tx_kind in &end_of_epoch_tx.transactions {
if let IotaEndOfEpochTransactionKind::ChangeEpoch(_change_epoch) = tx_kind {
if !got_epoch_change {
write_bs64_tx_to_file(
&raw_tx_bytes_to_transaction_data_bytes(&tx.raw_transaction)?,
"change-epoch",
)?;
got_epoch_change = true;
}
}
}
}
_ => {} // We don't care about other types for now
}
// Break if we got all types
if got_consensus_commit_prologue_v1 && got_epoch_change && got_genesis {
break;
}
}

if !(got_consensus_commit_prologue_v1 && got_epoch_change && got_genesis) {
panic!(
"Didn't get all transaction types: consensus_commit_prologue_v1: {got_consensus_commit_prologue_v1}, epoch_change: {got_epoch_change}, genesis: {got_genesis}"
);
}

Ok(())
}

// Write the tx data bytes base64 encoded to a file with the BASE_PATH before
// the provided name
fn write_bs64_tx_to_file(tx_data_bytes: &[u8], name: &str) -> Result<(), anyhow::Error> {
let mut f = OpenOptions::new()
.create(true)
.write(true)
.truncate(true)
.open(format!("{BASE_PATH}{name}"))?;
f.write_all(Base64::encode(tx_data_bytes).as_bytes())?;
f.flush()?;
Ok(())
}

fn raw_tx_bytes_to_transaction_data_bytes(raw_tx_bytes: &[u8]) -> Result<Vec<u8>, anyhow::Error> {
let sender_signed_data: SenderSignedData = bcs::from_bytes(raw_tx_bytes)?;
let tx_data = sender_signed_data.transaction_data();
let tx_data_bytes = bcs::to_bytes(tx_data)?;
Ok(tx_data_bytes)
}
28 changes: 5 additions & 23 deletions crates/iota-rust-sdk/src/types/transaction/serialization.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1253,29 +1253,11 @@ mod test {

#[test]
fn transaction_fixtures() {
// To update the fixtures use the iota-sdk, request a corresponding transaction
// and convert it to base64 like the following:
// let tx_response = client
// .read_api()
// .get_transaction_with_options(
// checkpoint.transactions[0],
// IotaTransactionBlockResponseOptions::new().with_raw_input(),
// )
// .await?;
// let sender_signed_data: iota_types::transaction::SenderSignedData =
// bcs::from_bytes(&tx_response.raw_transaction).unwrap();
// let tx_data = sender_signed_data.transaction_data();
// println!(
// "{}",
// <fastcrypto::encoding::Base64 as
// fastcrypto::encoding::Encoding>::encode(bcs::to_bytes(
// tx_data
// )?)
// );
const GENESIS_TRANSACTION: &str = include_str!("fixtures/genesis-transaction");
const CONSENSUS_PROLOGUE: &str = "AAJDAAAAAAAAAI4CAAAAAAAAAFGk2N2SAQAAIOILX2b6jMcm6eMh2PLilUlPkMHHA70qjw5m6HUBU45+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAA==";
const EPOCH_CHANGE: &str = "AAQBAEAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAML+1N2SAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAA";
const PTB: &str = "AAACAAgA0O2QLgAAAAAgERERERUE6TUOY11lzTjM0sApQ0xqOkgNiUepumoVshUCAgAFAQAAAQAAAQAAAQAAAQAAAQUDAAAAAAMAAAEAAwAAAgADAAADAAMAAAQAAQEA1dk1p8euO6O+qDrVqmJNGhat5thMVunhMP8bmDfnfiIBCOfaLD6XvxOgV5xdw7DDiE+wHdmBj3/e7d1XnRnMkj8BAAAAAAAAACBemVndc8ApfzVuUeaArMKKgsPMl8VFeGWYAzD8Hb5cfdXZNafHrjujvqg61apiTRoWrebYTFbp4TD/G5g3534i6AMAAAAAAAAA5AtUAgAAAAA=";
// Look in the fixtures folder to see how to update them
const GENESIS_TRANSACTION: &str = include_str!("fixtures/genesis");
const CONSENSUS_PROLOGUE: &str = include_str!("fixtures/consensus-commit-prologue-v1");
const EPOCH_CHANGE: &str = include_str!("fixtures/change-epoch");
const PTB: &str = include_str!("fixtures/ptb");

for fixture in [GENESIS_TRANSACTION, CONSENSUS_PROLOGUE, EPOCH_CHANGE, PTB] {
let fixture = Base64::decode_vec(fixture.trim()).unwrap();
Expand Down

0 comments on commit 8c849de

Please sign in to comment.