mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-11-07 19:31:07 +00:00
Fix flaky finalisation test (#4967)
This commit is contained in:
1 parent
9cc650d91c
commit
7f43796efc
1 file changed
+9
-2
@@ -515,8 +515,15 @@ fn fork_aware_finalization() {
|
||||
assert_eq!(stream.next(), Some(TransactionStatus::Ready));
|
||||
assert_eq!(stream.next(), Some(TransactionStatus::InBlock(c2.clone())));
|
||||
assert_eq!(stream.next(), Some(TransactionStatus::Retracted(c2)));
|
||||
assert_eq!(stream.next(), Some(TransactionStatus::Ready));
|
||||
assert_eq!(stream.next(), Some(TransactionStatus::InBlock(e1)));
|
||||
|
||||
// can be either Ready, or InBlock, depending on which event comes first
|
||||
assert_eq!(
|
||||
match stream.next() {
|
||||
Some(TransactionStatus::Ready) => stream.next(),
|
||||
val @ _ => val,
|
||||
},
|
||||
Some(TransactionStatus::InBlock(e1)),
|
||||
);
|
||||
assert_eq!(stream.next(), Some(TransactionStatus::Finalized(e1.clone())));
|
||||
assert_eq!(stream.next(), None);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user