I guess I don't see how setting a custom sys.excepthook will help me in this
case. I would like the exception that is raised to be recognized as a test
failure. The best that I could do is add some sort of a hack that attempts
to manually inject the error into the currently running test in a custom
sys.excepthook. Are there any other potential methods of accomplishing this?

Thanks,
Aron

On Sun, Mar 13, 2011 at 5:15 AM, Phil Thompson
<[email protected]>wrote:

> On Sun, 6 Mar 2011 20:04:17 -0600, Aron Bierbaum <[email protected]>
> wrote:
> > I have attached a sample test suite that shows an issue that we are
> running
> > into. The basic issue is that if an exception is raised in a method that
> is
> > connected to a Qt signal, the exception is only printed. I know that
> > translating the exception from Python to C++ and then back into Python
> is
> > difficult. But as the example shows the test suite can ignore real test
> > failures. Is there some way that PyQt could be changed to at least
> > translate
> > the exception type that can pass through C++ and back into Python?
> >
> > Thanks,
> > Aron
>
> The normal technique is to use sys.excepthook.
>
> Phil
>
_______________________________________________
PyQt mailing list    [email protected]
http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Reply via email to