Commit 22c22c17 authored by Jérome Perrin's avatar Jérome Perrin Committed by Xiaowu Zhang

ERP5TypeFunctionalTestCase: start Xvfb when running in debug mode without $DISPLAY

Otherwise running in debug mode on headless machines just display
cryptic error message.
parent 22f882c4
...@@ -153,7 +153,7 @@ class FunctionalTestRunner: ...@@ -153,7 +153,7 @@ class FunctionalTestRunner:
def test(self, debug=0): def test(self, debug=0):
xvfb = Xvfb(self.instance_home) xvfb = Xvfb(self.instance_home)
try: try:
if not debug: if not (debug and os.getenv('DISPLAY')):
print("\nSet 'erp5_debug_mode' environment variable to 1" print("\nSet 'erp5_debug_mode' environment variable to 1"
" to use your existing display instead of Xvfb.") " to use your existing display instead of Xvfb.")
xvfb.run() xvfb.run()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment