FIX: test left too early on false premise
diff --git a/test/netstd/Client/Performance/PerformanceTests.cs b/test/netstd/Client/Performance/PerformanceTests.cs
index c1f00dd..6ac3aed 100644
--- a/test/netstd/Client/Performance/PerformanceTests.cs
+++ b/test/netstd/Client/Performance/PerformanceTests.cs
@@ -132,10 +132,12 @@
{
var stop = new Stopwatch();
- if ((Testdata is null) || (Transport is null))
+ if (Testdata is null)
throw new Exception("unexpected internal state");
var proto = await factory(true);
+ if (Transport is null)
+ throw new Exception("unexpected internal state");
stop.Start();
await Testdata.WriteAsync(proto, Cancel.Token);
await Transport.FlushAsync(Cancel.Token);
@@ -146,6 +148,8 @@
var restored = new CrazyNesting();
proto = await factory(false);
+ if (Transport is null)
+ throw new Exception("unexpected internal state");
stop.Start();
await restored.ReadAsync(proto, Cancel.Token);
stop.Stop();