We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e102852 commit 5670ee5Copy full SHA for 5670ee5
src/ReactiveDomain.Testing/Messaging/ConcurrentMessageQueue.cs
@@ -56,8 +56,11 @@ public ConcurrentMessageQueue<T> AssertNext<TMsg>(
56
}
57
public void AssertEmpty()
58
{
59
- if (!IsEmpty)
60
- throw new Exception($" {_name} Queue not Empty.");
+ if (IsEmpty) return;
+ var errMsg = $"{_name} Queue is not Empty.";
61
+ if (TryPeek(out var msg))
62
+ errMsg += $" Instead {msg.GetType()} is next.";
63
+ throw new Exception(errMsg);
64
65
66
// JUST INHERITING EVERYTHING
0 commit comments