Skip to content

Commit a9abf1b

Browse files
authored
fix flake8-comprehensions warnings (#295)
1 parent e45426e commit a9abf1b

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

test/test_package_discovery.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -111,9 +111,9 @@ def test_discover_packages():
111111
descs = discover_packages(None, None, discovery_extensions=extensions)
112112
assert len(descs) == 2
113113
expected_path = '/extension1/pkg1'.replace('/', os.sep)
114-
assert expected_path in {str(d.path) for d in descs}
114+
assert expected_path in (str(d.path) for d in descs)
115115
expected_path = '/extension2/pkg1'.replace('/', os.sep)
116-
assert expected_path in {str(d.path) for d in descs}
116+
assert expected_path in (str(d.path) for d in descs)
117117

118118
# check with parameters
119119
extensions['extension3'].has_parameters = Mock(return_value=True)
@@ -125,9 +125,9 @@ def test_discover_packages():
125125
descs = discover_packages(None, None, discovery_extensions=extensions)
126126
assert len(descs) == 2
127127
expected_path = '/extension3/pkg1'.replace('/', os.sep)
128-
assert expected_path in {str(d.path) for d in descs}
128+
assert expected_path in (str(d.path) for d in descs)
129129
expected_path = '/extension3/pkg2'.replace('/', os.sep)
130-
assert expected_path in {str(d.path) for d in descs}
130+
assert expected_path in (str(d.path) for d in descs)
131131

132132

133133
def test__get_extensions_with_parameters():
@@ -197,6 +197,6 @@ def test__discover_packages():
197197

198198
assert len(descs) == 2
199199
expected_path = '/extension3/pkg1'.replace('/', os.sep)
200-
assert expected_path in {str(d.path) for d in descs}
200+
assert expected_path in (str(d.path) for d in descs)
201201
expected_path = '/extension3/pkg2'.replace('/', os.sep)
202-
assert expected_path in {str(d.path) for d in descs}
202+
assert expected_path in (str(d.path) for d in descs)

0 commit comments

Comments
 (0)