Commit cdd42298 authored by Benjamin Berg's avatar Benjamin Berg Committed by Carlos Garnacho
Browse files

tests: Unset display environment variables

The environment variables were not correctly cleared. Fix this and also
make sure that we don't have the GNOME_SETUP_DISPLAY environment
variable leaking in from the outside.
parent 70cadb75
...@@ -94,7 +94,10 @@ class X11SessionTestCase(DBusTestCase): ...@@ -94,7 +94,10 @@ class X11SessionTestCase(DBusTestCase):
klass.X_display = display klass.X_display = display
# Export information into our environment for tests to use # Export information into our environment for tests to use
os.environ['DISPLAY'] = ":%d" % klass.X_display os.environ['DISPLAY'] = ":%d" % klass.X_display
os.environ['WAYLAND'] = '' if 'GNOME_SETUP_DISPLAY' in os.environ:
del os.environ['GNOME_SETUP_DISPLAY']
if 'WAYLAND_DISPLAY' in os.environ:
del os.environ['WAYLAND_DISPLAY']
# Server should still be up and running at this point # Server should still be up and running at this point
assert klass.xorg.poll() is None assert klass.xorg.poll() is None
......
Supports Markdown
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