Fix issues with Python 3.5
This commit is contained in:
parent
e482c76874
commit
9685445559
@ -447,7 +447,7 @@ class Config(QObject):
|
|||||||
The changed config part as string.
|
The changed config part as string.
|
||||||
"""
|
"""
|
||||||
blocks = []
|
blocks = []
|
||||||
for values in self:
|
for values in sorted(self, key=lambda v: v.opt.name):
|
||||||
if values:
|
if values:
|
||||||
blocks.append(str(values))
|
blocks.append(str(values))
|
||||||
|
|
||||||
|
@ -530,7 +530,7 @@ class TestConfig:
|
|||||||
"""Make sure mutable types are only copied once."""
|
"""Make sure mutable types are only copied once."""
|
||||||
spy = mocker.spy(config.copy, 'deepcopy')
|
spy = mocker.spy(config.copy, 'deepcopy')
|
||||||
conf.get_mutable_obj('bindings.commands')
|
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):
|
def test_get_obj_for_pattern(self, conf):
|
||||||
pattern = urlmatch.UrlPattern('*://example.com')
|
pattern = urlmatch.UrlPattern('*://example.com')
|
||||||
|
@ -186,8 +186,8 @@ class TestEarlyInit:
|
|||||||
|
|
||||||
if config_py and load_autoconfig and not invalid_yaml:
|
if config_py and load_autoconfig and not invalid_yaml:
|
||||||
expected = [
|
expected = [
|
||||||
'colors.hints.fg = magenta',
|
|
||||||
'colors.hints.bg = red',
|
'colors.hints.bg = red',
|
||||||
|
'colors.hints.fg = magenta',
|
||||||
]
|
]
|
||||||
elif config_py:
|
elif config_py:
|
||||||
expected = ['colors.hints.bg = red']
|
expected = ['colors.hints.bg = red']
|
||||||
|
Loading…
Reference in New Issue
Block a user