mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-23 11:12:47 +01:00
Added check of world.testing so nasty exceptions aren't printed during testing.
This commit is contained in:
parent
6f7a33ce5c
commit
822a12535b
@ -40,6 +40,7 @@ import traceback
|
|||||||
|
|
||||||
import ansi
|
import ansi
|
||||||
import conf
|
import conf
|
||||||
|
import world
|
||||||
|
|
||||||
###
|
###
|
||||||
# CONFIGURATION
|
# CONFIGURATION
|
||||||
@ -130,6 +131,8 @@ def unrecoverableError(msg):
|
|||||||
exit(-1)
|
exit(-1)
|
||||||
|
|
||||||
def recoverableException():
|
def recoverableException():
|
||||||
|
if world.testing:
|
||||||
|
return
|
||||||
(E, e, tb) = sys.exc_info()
|
(E, e, tb) = sys.exc_info()
|
||||||
for exn in deadlyExceptions:
|
for exn in deadlyExceptions:
|
||||||
if issubclass(e.__class__, exn):
|
if issubclass(e.__class__, exn):
|
||||||
|
Loading…
Reference in New Issue
Block a user