mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-08 20:29:23 +00:00
Use a single Substrate signer, per intentions in #227
Removes key from Update as well, since it's no longer variable.
This commit is contained in:
@@ -51,8 +51,7 @@ async fn spend<N: Network, D: Db>(
|
||||
network.mine_block().await;
|
||||
}
|
||||
match timeout(Duration::from_secs(30), scanner.events.recv()).await.unwrap().unwrap() {
|
||||
ScannerEvent::Block { key: this_key, block: _, outputs } => {
|
||||
assert_eq!(this_key, key);
|
||||
ScannerEvent::Block { block: _, outputs } => {
|
||||
assert_eq!(outputs.len(), 1);
|
||||
// Make sure this is actually a change output
|
||||
assert_eq!(outputs[0].kind(), OutputType::Change);
|
||||
@@ -89,8 +88,7 @@ pub async fn test_addresses<N: Network>(network: N) {
|
||||
// Verify the Scanner picked them up
|
||||
let outputs =
|
||||
match timeout(Duration::from_secs(30), scanner.events.recv()).await.unwrap().unwrap() {
|
||||
ScannerEvent::Block { key: this_key, block, outputs } => {
|
||||
assert_eq!(this_key, key);
|
||||
ScannerEvent::Block { block, outputs } => {
|
||||
assert_eq!(block, block_id);
|
||||
assert_eq!(outputs.len(), 1);
|
||||
assert_eq!(outputs[0].kind(), OutputType::Branch);
|
||||
|
||||
@@ -55,8 +55,7 @@ pub async fn test_scanner<N: Network>(network: N) {
|
||||
let verify_event = |mut scanner: ScannerHandle<N, MemDb>| async {
|
||||
let outputs =
|
||||
match timeout(Duration::from_secs(30), scanner.events.recv()).await.unwrap().unwrap() {
|
||||
ScannerEvent::Block { key, block, outputs } => {
|
||||
assert_eq!(key, keys.group_key());
|
||||
ScannerEvent::Block { block, outputs } => {
|
||||
assert_eq!(block, block_id);
|
||||
assert_eq!(outputs.len(), 1);
|
||||
assert_eq!(outputs[0].kind(), OutputType::External);
|
||||
|
||||
@@ -36,8 +36,7 @@ pub async fn test_wallet<N: Network>(network: N) {
|
||||
let block_id = block.id();
|
||||
|
||||
match timeout(Duration::from_secs(30), scanner.events.recv()).await.unwrap().unwrap() {
|
||||
ScannerEvent::Block { key: this_key, block, outputs } => {
|
||||
assert_eq!(this_key, key);
|
||||
ScannerEvent::Block { block, outputs } => {
|
||||
assert_eq!(block, block_id);
|
||||
assert_eq!(outputs.len(), 1);
|
||||
(block_id, outputs)
|
||||
@@ -109,8 +108,7 @@ pub async fn test_wallet<N: Network>(network: N) {
|
||||
}
|
||||
|
||||
match timeout(Duration::from_secs(30), scanner.events.recv()).await.unwrap().unwrap() {
|
||||
ScannerEvent::Block { key: this_key, block: block_id, outputs: these_outputs } => {
|
||||
assert_eq!(this_key, key);
|
||||
ScannerEvent::Block { block: block_id, outputs: these_outputs } => {
|
||||
assert_eq!(block_id, block.id());
|
||||
assert_eq!(these_outputs, outputs);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user