2
2
3
3
from node .blockchain .facade import BlockchainFacade
4
4
from node .blockchain .tests .factories .node import make_node
5
+ from node .blockchain .tests .factories .signed_change_request .coin_transfer import (
6
+ make_coin_transfer_signed_change_request
7
+ )
5
8
from node .blockchain .tests .factories .signed_change_request .node_declaration import (
6
9
make_node_declaration_signed_change_request
7
10
)
@@ -22,14 +25,10 @@ def base_blockchain(genesis_block_message, primary_validator_key_pair, db):
22
25
23
26
@pytest .fixture
24
27
def rich_blockchain (
25
- base_blockchain ,
26
- primary_validator_key_pair ,
27
- confirmation_validator_key_pair ,
28
- confirmation_validator_key_pair_2 ,
29
- regular_node_declaration_signed_change_request ,
30
- self_node_declaration_signed_change_request ,
28
+ base_blockchain , primary_validator_key_pair , confirmation_validator_key_pair , confirmation_validator_key_pair_2 ,
29
+ regular_node_declaration_signed_change_request , self_node_declaration_signed_change_request ,
31
30
confirmation_validator_declaration_signed_change_request ,
32
- confirmation_validator_2_declaration_signed_change_request ,
31
+ confirmation_validator_2_declaration_signed_change_request , treasury_account_key_pair , regular_node , self_node
33
32
):
34
33
blockchain_facade = BlockchainFacade .get_instance ()
35
34
@@ -67,6 +66,14 @@ def rich_blockchain(
67
66
validate = False ,
68
67
)
69
68
69
+ blockchain_facade .add_block_from_signed_change_request (
70
+ signed_change_request = make_coin_transfer_signed_change_request (
71
+ treasury_account_key_pair , regular_node .identifier , self_node .identifier
72
+ ),
73
+ signing_key = primary_validator_key_pair .private ,
74
+ validate = False ,
75
+ )
76
+
70
77
# TODO(dmu) MEDIUM: Add more blocks as new block types are developed
71
78
72
79
0 commit comments