Skip to content

Commit

Permalink
Fix tests and remove duplicate _WITHDRAWAL_PREFIX definition
Browse files Browse the repository at this point in the history
  • Loading branch information
hwwhww committed Jun 14, 2024
1 parent aa65fd7 commit 718aadf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 0 additions & 2 deletions specs/electra/beacon-chain.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,6 @@ The following values are (non-configurable) constants used throughout the specif

| Name | Value |
| - | - |
| `BLS_WITHDRAWAL_PREFIX` | `Bytes1('0x00')` |
| `ETH1_ADDRESS_WITHDRAWAL_PREFIX` | `Bytes1('0x01')` |
| `COMPOUNDING_WITHDRAWAL_PREFIX` | `Bytes1('0x02')` |

### Domains
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,9 @@ def test_initialize_beacon_state_some_small_balances(spec):
assert state.eth1_data.deposit_count == len(deposits)
assert state.eth1_data.block_hash == eth1_block_hash
# only main deposits participate to the active balance
assert spec.get_total_active_balance(state) == main_deposit_count * max_effective_balance
# NOTE: they are pre-ELECTRA deposits with BLS_WITHDRAWAL_PREFIX,
# so `MAX_EFFECTIVE_BALANCE` is used
assert spec.get_total_active_balance(state) == main_deposit_count * spec.MAX_EFFECTIVE_BALANCE

# yield state
yield 'state', state
Expand Down

0 comments on commit 718aadf

Please sign in to comment.