File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -294,6 +294,16 @@ def sample_validator_record_params():
294
294
}
295
295
296
296
297
+ @pytest .fixture
298
+ def sample_validator_registry_delta_block_params ():
299
+ return {
300
+ 'latest_registry_delta_root' : b'\x01 ' * 32 ,
301
+ 'validator_index' : 1 ,
302
+ 'pubkey' : 123 ,
303
+ 'flag' : 1 ,
304
+ }
305
+
306
+
297
307
#
298
308
# Temporary default values
299
309
#
Original file line number Diff line number Diff line change
1
+ from eth .beacon .types .validator_registry_delta_block import (
2
+ ValidatorRegistryDeltaBlock ,
3
+ )
4
+
5
+
6
+ def test_defaults (sample_validator_registry_delta_block_params ):
7
+ validator_registry_delta_block = ValidatorRegistryDeltaBlock (
8
+ ** sample_validator_registry_delta_block_params
9
+ )
10
+ assert validator_registry_delta_block .latest_registry_delta_root == sample_validator_registry_delta_block_params ['latest_registry_delta_root' ] # noqa: E501
11
+ assert validator_registry_delta_block .validator_index == sample_validator_registry_delta_block_params ['validator_index' ] # noqa: E501
12
+ assert validator_registry_delta_block .pubkey == sample_validator_registry_delta_block_params ['pubkey' ] # noqa: E501
13
+ assert validator_registry_delta_block .flag == sample_validator_registry_delta_block_params ['flag' ] # noqa: E501
You can’t perform that action at this time.
0 commit comments