(
to: Account,
blockchain: Arc<Mutex<BlockChain>>,
)
| 295 | } |
| 296 | |
| 297 | pub(crate) async fn new_transaction( |
| 298 | to: Account, |
| 299 | blockchain: Arc<Mutex<BlockChain>>, |
| 300 | ) -> Transaction { |
| 301 | let nonce = blockchain |
| 302 | .lock() |
| 303 | .await |
| 304 | .accounts |
| 305 | .get_account(&ACCOUNT_1) |
| 306 | .unwrap_or(AccountData::new(None)) |
| 307 | .nonce |
| 308 | + 1; |
| 309 | |
| 310 | let transaction = |
| 311 | Transaction::new(*ACCOUNT_1, Some(to), U256::from(10), Some(nonce), None).unwrap(); |
| 312 | |
| 313 | transaction |
| 314 | } |
| 315 | |
| 316 | pub(crate) async fn process_transactions(blockchain: Arc<Mutex<BlockChain>>) { |
| 317 | blockchain |
no test coverage detected