@@ -183,14 +183,14 @@ def teardown_class(cls):
183
183
}
184
184
185
185
@pytest .mark .asyncio
186
- @pytest .mark .skipif (EXTERNAL_SYSTEM () != 1 , reason = "Needs network connection." )
186
+ @pytest .mark .skipif (not EXTERNAL_SYSTEM (), reason = "Needs network connection." )
187
187
async def test_update_ecosystems (self ):
188
188
await self .osv .update_ecosystems ()
189
189
190
190
assert all (x in self .osv .ecosystems for x in self .ecosystems )
191
191
192
192
@pytest .mark .asyncio
193
- @pytest .mark .skipif (EXTERNAL_SYSTEM () != 1 , reason = "Needs network connection." )
193
+ @pytest .mark .skipif (not EXTERNAL_SYSTEM (), reason = "Needs network connection." )
194
194
@pytest .mark .parametrize ("ecosystem_url" , [url for url in cve_file_data ])
195
195
async def test_get_ecosystem_00 (self , ecosystem_url ):
196
196
connector = aiohttp .TCPConnector (limit_per_host = 19 )
@@ -205,7 +205,7 @@ async def test_get_ecosystem_00(self, ecosystem_url):
205
205
assert content ["published" ] == cve_data ["published" ]
206
206
207
207
@pytest .mark .asyncio
208
- @pytest .mark .skipif (EXTERNAL_SYSTEM () != 1 , reason = "Needs network connection." )
208
+ @pytest .mark .skipif (not EXTERNAL_SYSTEM (), reason = "Needs network connection." )
209
209
async def test_get_ecosystem_01 (self ):
210
210
eco_url = f"{ self .osv_url } DWF/all.zip"
211
211
@@ -221,7 +221,7 @@ async def test_get_ecosystem_01(self):
221
221
assert len (z .namelist ()) == 0
222
222
223
223
@pytest .mark .asyncio
224
- @pytest .mark .skipif (EXTERNAL_SYSTEM () != 1 , reason = "Needs network connection." )
224
+ @pytest .mark .skipif (not EXTERNAL_SYSTEM (), reason = "Needs network connection." )
225
225
async def test_fetch_cves (self ):
226
226
self .osv .ecosystems = ["PyPI" ]
227
227
0 commit comments