Commit Graph

1 Commits

Author SHA1 Message Date
Ivan Martinez
4976461e62 Implement GenesisBlock() to Grab the Block from Memory DB (#373)
* Fix odd placement of import

* Puts all of NewGenesisBlock() into GenesisBlock() 

Also removes the unneeded TODO

* Add error check for db retrieval

* Add missing bazel imports

* Add back NewGenesisBlock and create GenesisBlock in NewBeaconChian

* Fix GenesisBlock() to grab the block from memory db

* Fix according to requested changes

Fix GenesisBlock() to grab the block from memory db
Fix odd placement of import


Properly add ParentHash to Block


Remove no longer needed if statement condition


Puts all of NewGenesisBlock() into GenesisBlock() 

Also removes the unneeded TODO
Add error check for db retrieval


Add case for if the beaconChain is missing a genesisBlock


Add missing bazel imports


Add back NewGenesisBlock and create GenesisBlock in NewBeaconChian


Remove duplicate code


Change genesis block timestamp to unix 0


Adds info log when a genesis block isn't found

* Provide fakeClock to pass tests with a mocked genesisBlock

* Fix unexpected log in test from addition of genesis block

* Add tests for clock
2018-08-12 22:07:37 -04:00