Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(test): First 11 cellbases have not outputs #1684

Merged
merged 1 commit into from
Oct 9, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions test/src/specs/sync/chain_forks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -624,6 +624,11 @@ impl Spec for ForkedTransaction {
let node0 = &net.nodes[0];
let node1 = &net.nodes[1];
let finalization_delay_length = node0.consensus().finalization_delay_length();
(0..=finalization_delay_length).for_each(|_| {
let block = node0.new_block(None, None, None);
node0.submit_block(&block.data());
node1.submit_block(&block.data());
});

net.exit_ibd_mode();
let fixed_point = node0.get_tip_block_number();
Expand Down
2 changes: 1 addition & 1 deletion test/src/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ pub fn generate_utxo_set(node: &Node, n: usize) -> TXOSet {
let mature_number = node.get_tip_block_number() - cellbase_maturity.index();
let mature_block = node.get_block_by_number(mature_number);
let mature_cellbase = mature_block.transaction(0).unwrap();
if mature_cellbase.outputs().len() == 0 {
if mature_cellbase.outputs().is_empty() {
continue;
}

Expand Down