Fix argparser test after win_registry change.

The last focused window was now window 1 - so we better make this explicit.
This commit is contained in:
Florian Bruhin 2015-08-23 22:37:27 +02:00
parent 7bc5996d52
commit 70243d6e2f
2 changed files with 3 additions and 1 deletions

View File

@ -96,7 +96,7 @@ def win_registry():
window2 = FakeWindow(registry2)
objreg.window_registry[0] = window1
objreg.window_registry[1] = window2
yield
yield [window1, window2]
del objreg.window_registry[1]
del objreg.window_registry[0]

View File

@ -47,8 +47,10 @@ class TestArgumentParser:
@pytest.yield_fixture
def tabbed_browser(self, win_registry):
tb = FakeTabbedBrowser()
objreg.register('last-focused-main-window', win_registry[0])
objreg.register('tabbed-browser', tb, scope='window', window=0)
yield tb
objreg.delete('last-focused-main-window')
objreg.delete('tabbed-browser', scope='window', window=0)
def test_name(self, parser):