Skip to content

Commit b9fa18b

Browse files
committed
TST: enable warnings in our test script
1 parent 5540fde commit b9fa18b

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/diffpy/pdfgui/tests/run.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@
2121

2222
if __name__ == '__main__':
2323
import sys
24+
# show warnings by default
25+
if not sys.warnoptions:
26+
import os, warnings
27+
warnings.simplefilter("default")
28+
# also affect subprocesses
29+
os.environ["PYTHONWARNINGS"] = "default"
2430
from diffpy.pdfgui.tests import test
2531
# produce zero exit code for a successful test
2632
sys.exit(not test().wasSuccessful())

0 commit comments

Comments
 (0)