Use inline list comprehension for parametrize expression
This commit is contained in:
parent
6e3c3d7a70
commit
fd88311d9b
@ -337,12 +337,9 @@ class TestBool:
|
||||
def setup(self):
|
||||
self.t = configtypes.Bool()
|
||||
|
||||
_ALL_FORMS = []
|
||||
for out, inputs in TESTS.items():
|
||||
for inp in inputs:
|
||||
_ALL_FORMS.append((out, inp))
|
||||
|
||||
@pytest.mark.parametrize('out, inp', _ALL_FORMS)
|
||||
@pytest.mark.parametrize('out, inp',
|
||||
[(out, inp) for out, inputs in TESTS.items() for
|
||||
inp in inputs])
|
||||
def test_transform(self, out, inp):
|
||||
"""Test transform with all values."""
|
||||
assert self.t.transform(inp) == out
|
||||
|
Loading…
Reference in New Issue
Block a user