Merge pull request #350 from ethcore/signed_transaction

SignedTransaction structure
This commit is contained in:
Marek Kotewicz
2016-02-05 14:11:12 +01:00
12 changed files with 256 additions and 213 deletions

View File

@@ -123,12 +123,12 @@ fn create_unverifiable_block(order: u32, parent_hash: H256) -> Bytes {
create_test_block(&create_unverifiable_block_header(order, parent_hash))
}
pub fn create_test_block_with_data(header: &Header, transactions: &[&Transaction], uncles: &[Header]) -> Bytes {
pub fn create_test_block_with_data(header: &Header, transactions: &[&SignedTransaction], uncles: &[Header]) -> Bytes {
let mut rlp = RlpStream::new_list(3);
rlp.append(header);
rlp.begin_list(transactions.len());
for t in transactions {
rlp.append_raw(&t.rlp_bytes_opt(Seal::With), 1);
rlp.append_raw(&encode::<SignedTransaction>(t).to_vec(), 1);
}
rlp.append(&uncles);
rlp.out()