Fix pylint/flake8 errors in configtypes.

This commit is contained in:
Ryan Roden-Corrent 2018-10-03 21:44:10 -04:00
parent 59f9d31d4b
commit a5b3670477
No known key found for this signature in database
GPG Key ID: 4E5072F68872BC04
2 changed files with 2 additions and 4 deletions

View File

@ -934,9 +934,9 @@ class QtColor(BaseType):
if kind == 'rgba' and len(vals) == 4:
return QColor.fromRgb(*vals)
elif kind == 'rgb' and len(vals) == 3:
return QColor.fromRgb(*vals)
return QColor.fromRgb(*vals)
elif kind == 'hsva' and len(vals) == 4:
return QColor.fromHsv(*vals)
return QColor.fromHsv(*vals)
elif kind == 'hsv' and len(vals) == 3:
return QColor.fromHsv(*vals)
else:

View File

@ -21,7 +21,6 @@
import re
import json
import math
import itertools
import warnings
import inspect
import functools
@ -1245,7 +1244,6 @@ class TestQtColor:
('hsva(10%,20%,30%,40%)', QColor.fromHsv(25, 51, 76, 102)),
])
def test_valid(self, val, expected):
act = configtypes.QtColor().to_py(val)
assert configtypes.QtColor().to_py(val) == expected
@pytest.mark.parametrize('val', [