mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-09 04:39:24 +00:00
Handle signing batches in the processor
Duplicates the existing signer for one tailored to batch signing.
This commit is contained in:
@@ -40,15 +40,18 @@ pub async fn test_scanner<C: Coin>(coin: C) {
|
||||
let scanner = new_scanner().await;
|
||||
|
||||
// Receive funds
|
||||
let block_id = coin.test_send(C::address(keys.group_key())).await.id();
|
||||
let block = coin.test_send(C::address(keys.group_key())).await;
|
||||
let block_id = block.id();
|
||||
let block_time = block.time();
|
||||
|
||||
// Verify the Scanner picked them up
|
||||
let verify_event = |mut scanner: ScannerHandle<C, MemDb>| async {
|
||||
let outputs =
|
||||
match timeout(Duration::from_secs(30), scanner.events.recv()).await.unwrap().unwrap() {
|
||||
ScannerEvent::Outputs(key, block, outputs) => {
|
||||
ScannerEvent::Block(key, block, time, outputs) => {
|
||||
assert_eq!(key, keys.group_key());
|
||||
assert_eq!(block, block_id);
|
||||
assert_eq!(time, block_time);
|
||||
assert_eq!(outputs.len(), 1);
|
||||
assert_eq!(outputs[0].kind(), OutputType::External);
|
||||
outputs
|
||||
|
||||
Reference in New Issue
Block a user