Fix issues with Python 3.5

This commit is contained in:
Florian Bruhin 2018-02-20 17:22:11 +01:00
parent e482c76874
commit 9685445559
3 changed files with 3 additions and 3 deletions

View File

@ -447,7 +447,7 @@ class Config(QObject):
The changed config part as string.
"""
blocks = []
for values in self:
for values in sorted(self, key=lambda v: v.opt.name):
if values:
blocks.append(str(values))

View File

@ -530,7 +530,7 @@ class TestConfig:
"""Make sure mutable types are only copied once."""
spy = mocker.spy(config.copy, 'deepcopy')
conf.get_mutable_obj('bindings.commands')
spy.assert_called_once()
spy.assert_called_once_with(mocker.ANY)
def test_get_obj_for_pattern(self, conf):
pattern = urlmatch.UrlPattern('*://example.com')

View File

@ -186,8 +186,8 @@ class TestEarlyInit:
if config_py and load_autoconfig and not invalid_yaml:
expected = [
'colors.hints.fg = magenta',
'colors.hints.bg = red',
'colors.hints.fg = magenta',
]
elif config_py:
expected = ['colors.hints.bg = red']