Closed plemarquand closed 3 weeks ago
If a build fails and I click on debug anyway
in the dialog, it doesn't run the debug anymore
EDIT: I think you can get rid of the if (buildFailed)
section as if the build fails, started is set to false, if you want to change the error message check it in the else block of if (started)
If a build fails and I click on debug anyway in the dialog, it doesn't run the debug anymore
So it works for me IFF it succeeded building before. So if delete .build and try to debug the test with build errors, even if I click Debug Anyway, the LLDB extension bails on the debug session. But if the build succeeds once and then introduce the error, then Debug Anyway runs
"Debug Anyway" is problematic. Right now when debugging swift-testing tests, if Build All fails we close out the named pipe listening for test results. Then the user hits "Debug Anyway" and the pipe has been closed, and no test results arrive and the test run hangs forever.
If we don't close out the named pipe on build failure and the user hits "Abort", then the named pipe stays open and subsequent test runs hang forever.
I've broken out the build step when debugging and if there is a failure we exit before the debugger is started, sidestepping this issue.
When debugging an XCTest that fails to build the debugger promise rejects but did not provide an error. The undefined error is caught and passed to
getErrorDescription
which fails to readstderr
off of it. This caused another error to be thrown and caught at the top level, showing a dialog.Throw an error string instead of undefined, and handle the undefined error case in getErrorDescription.