private async Task InteropTestCase(string name) { using (var serverProcess = new WebsiteProcess(_serverPath, _output)) { await serverProcess.WaitForReady().TimeoutAfter(DefaultTimeout); using (var clientProcess = new ClientProcess(_output, _clientPath, serverProcess.ServerPort, name)) { try { await clientProcess.WaitForReadyAsync().TimeoutAfter(DefaultTimeout); await clientProcess.WaitForExitAsync().TimeoutAfter(DefaultTimeout); Assert.Equal(0, clientProcess.ExitCode); } catch (Exception ex) { var clientOutput = clientProcess.GetOutput(); var errorMessage = $@"Error while running client process. Process output: ====================================== {clientOutput}"; throw new InvalidOperationException(errorMessage, ex); } } } }