From 0e9a82711cc8947ad6539a507f4d893772da982b Mon Sep 17 00:00:00 2001 From: Conrad Irwin Date: Tue, 31 Oct 2023 16:04:33 +0000 Subject: [PATCH] Actually deliver test events to subscribers --- crates/gpui2/src/app/test_context.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/gpui2/src/app/test_context.rs b/crates/gpui2/src/app/test_context.rs index f590d05c6c..00712eba50 100644 --- a/crates/gpui2/src/app/test_context.rs +++ b/crates/gpui2/src/app/test_context.rs @@ -161,8 +161,8 @@ impl TestAppContext { let (mut tx, rx) = futures::channel::mpsc::unbounded(); entity .update(self, |_, cx: &mut ModelContext| { - cx.subscribe(&entity, move |_, _, event, _| { - let _ = tx.send(event.clone()); + cx.subscribe(&entity, move |_, _, event, cx| { + cx.executor().block(tx.send(event.clone())).unwrap(); }) }) .detach();