Source

pida-patches / test-workpsace-window

# HG changeset patch
# Parent 018d5f93ed1f076609902cc5871148d786e5bebe
test workspace window

diff --git a/tests/ui/test_window.py b/tests/ui/test_window.py
--- a/tests/ui/test_window.py
+++ b/tests/ui/test_window.py
@@ -1,7 +1,7 @@
 
 from pida.utils.testing import refresh_gui
 from pida.utils.testing.mock import Mock
-from pida.ui.window import PidaWindow
+from pida.ui.window import PidaWindow, WorkspaceWindow
 from pida.core.boss import Boss
 from pida.services.window.window import Window as WindowSvc
 
@@ -33,4 +33,12 @@ def test_svc_setup(boss, monkeypatch, tm
     svc.save_state()
 
 
+from pida.core import options
+from pida.utils import pdbus
 
+def test_workspace_window(monkeypatch):
+    monkeypatch.setattr(pdbus, 'list_pida_instances', lambda **kw: None)
+    monkeypatch.setattr(options, 'list_workspaces', lambda: ['default'])
+    w = WorkspaceWindow()
+    refresh_gui()
+