forked from CleanCut/green
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
report unhandled exception in testing framework
Fixes CleanCut#60 - uncaught exception from testcase - exit without traceback
- Loading branch information
1 parent
6c72401
commit 572737c
Showing
1 changed file
with
12 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
572737c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmmm. What about when we're running tests in subprocesses?
I'm working on writing test cases to cover the single-process condition (which I think your code will handle) and the multiple-process condition.
You can use the
g
stub to help test in-place code, by the way. It's a lot easier than trying to install your custom changes../g -r
is a good way to check your coverage for single-process../g -r -s 0
is a good way to check your coverage for multiple processes. (You'll see a bunch of unfinished multi-process work not covered -- I'm working on that in another branch right now).572737c
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, I'm getting real sick of dealing with single-process logic separate from multiprocess logic. Now may be a good time to just make the default run actually use the multiprocess architecture I have in place (just with 1 worker). Then we can just deal with the multiprocess issues as they come up. Like the fact that a crash in a process that's a worker for a pool gets silently ignored and the worker just gets restarted, unless you do something yourself to handle it.
So that's what I'm experimenting with in conjunction with this catch-unexpected-exceptions idea.