Basic Authority (#991)

* Firt commit.

* First non-functional but correct implementation of BasicAuthority.

Still needs:
- Sealing infrastructure.

* Punch a hole to give miner access to key store.

* Fix test built.

* Basic version of synchronous mining.

This will seal a block whenever a new transaction comes through.
To be made better we need a timer which will wait for one second after the
last block before sealing a new one - better still would be to cooperatively
interleave blocks with other sealing nodes.

* Add tests.

* Fix minor issues from repotting.

* Address grumbles.
This commit is contained in:
Gav Wood
2016-05-03 17:23:53 +02:00
parent 1583f7d434
commit ac73b2628a
34 changed files with 506 additions and 88 deletions

View File

@@ -1484,7 +1484,7 @@ mod tests {
}
fn dummy_sync_with_peer(peer_latest_hash: H256) -> ChainSync {
let mut sync = ChainSync::new(SyncConfig::default(), Miner::new(false));
let mut sync = ChainSync::new(SyncConfig::default(), Arc::new(Miner::default()));
sync.peers.insert(0,
PeerInfo {
protocol_version: 0,