prysm-pulse/contracts
Raul Jordan b6cd890a67 Log Verbosity Flags + Logrus Package Level Logs With Fields (#304)
Former-commit-id: f7344b7d3fb2fa07f0fd421c5ed3721f6c7a9258 [formerly e678ab2f1681d9492c0e1b142cd06ee08a462fdb]
Former-commit-id: d942da3d5cfcde921bebb149c26edd5c4ed178dd
2018-07-21 12:51:18 -05:00
..
deployVRC Log Verbosity Flags + Logrus Package Level Logs With Fields (#304) 2018-07-21 12:51:18 -05:00
BUILD.bazel Rename Entire Project to Repo, Change Import Paths and Readmes (#298) 2018-07-20 16:31:26 -05:00
README.md Fix Bazel Build Rules for Visibility, Move LICENSE to Top-Level (#253) 2018-07-12 12:00:37 -05:00
validator_registration_test.go beacon: Define a Core Blockchain Package and Persisted Structure for Beacon (#278) 2018-07-19 11:31:50 -05:00
validator_registration.go beacon: Define a Core Blockchain Package and Persisted Structure for Beacon (#278) 2018-07-19 11:31:50 -05:00
validator_registration.sol beacon: Define a Core Blockchain Package and Persisted Structure for Beacon (#278) 2018-07-19 11:31:50 -05:00

Validator Registration Contract

For beacon chain design, a validator will deposit 32 ETH to the main chain smart contract. The deposit is considered to be burned. As you burn the 32 ETH to participate, the beacon chain will see it and will credit the validator with the validator bond, and the validator can begin to validate. At some point in the future, after a hard fork, the original deposit + interest can be withdrawn back on one of the shards.

How to execute tests

go test ./...

Run with -v option for detailed log output

go test ./... -v
=== RUN   TestSetupAndContractRegistration
--- PASS: TestSetupAndContractRegistration (0.01s)
=== RUN   TestRegisterWithLessThan32Eth
--- PASS: TestRegisterWithLessThan32Eth (0.00s)
=== RUN   TestRegisterWithMoreThan32Eth
--- PASS: TestRegisterWithMoreThan32Eth (0.00s)
=== RUN   TestRegisterTwice
--- PASS: TestRegisterTwice (0.01s)
=== RUN   TestRegister
--- PASS: TestRegister (0.01s)
PASS
ok      beacon-chain/contracts  0.151s