test effort

This commit is contained in:
Nikolay Volf
2016-02-05 02:57:51 +03:00
parent 0c90b75c67
commit b0cba757d6
2 changed files with 35 additions and 1 deletions

View File

@@ -117,7 +117,14 @@ impl BlockChainClient for TestBlockChainClient {
})
}
fn state_data(&self, _h: &H256) -> Option<Bytes> {
// TODO: returns just hashes instead of node state rlp(?)
fn state_data(&self, hash: &H256) -> Option<Bytes> {
// starts with 'f' ?
if *hash > H256::from("f000000000000000000000000000000000000000000000000000000000000000") {
let mut rlp = RlpStream::new();
rlp.append(&hash.clone());
return Some(rlp.out());
}
None
}