From: Roland Mas <roland.mas@entierement.net>
Date: Thu, 8 May 2025 17:05:32 +0200
Subject: Skip tests that require networking

---
 napari_plugin_manager/_tests/test_installer_process.py | 2 ++
 napari_plugin_manager/_tests/test_npe2api.py           | 5 +++++
 2 files changed, 7 insertions(+)

diff --git a/napari_plugin_manager/_tests/test_installer_process.py b/napari_plugin_manager/_tests/test_installer_process.py
index 9b89103..82a8454 100644
--- a/napari_plugin_manager/_tests/test_installer_process.py
+++ b/napari_plugin_manager/_tests/test_installer_process.py
@@ -60,6 +60,7 @@ class _NonExistingTool(AbstractInstallerTool):
         return QProcessEnvironment.systemEnvironment()
 
 
+@pytest.mark.needs_network
 def test_pip_installer_tasks(
     qtbot, tmp_virtualenv: 'Session', monkeypatch, caplog
 ):
@@ -358,6 +359,7 @@ def test_executables():
     assert NapariPipInstallerTool.executable()
 
 
+@pytest.mark.needs_network
 def test_available():
     assert str(NapariCondaInstallerTool.available())
     assert NapariPipInstallerTool.available()
diff --git a/napari_plugin_manager/_tests/test_npe2api.py b/napari_plugin_manager/_tests/test_npe2api.py
index a981f44..74d73d0 100644
--- a/napari_plugin_manager/_tests/test_npe2api.py
+++ b/napari_plugin_manager/_tests/test_npe2api.py
@@ -8,12 +8,14 @@ from napari_plugin_manager.npe2api import (
     plugin_summaries,
 )
 
+import pytest
 
 def test_user_agent():
     assert _user_agent()
 
 
 @flaky(max_runs=4, min_passes=2)
+@pytest.mark.needs_network
 def test_plugin_summaries():
     keys = [
         "name",
@@ -35,6 +37,7 @@ def test_plugin_summaries():
     assert not test_data
 
 
+@pytest.mark.needs_network
 def test_conda_map():
     pkgs = ["napari-svg"]
     data = conda_map()
@@ -42,12 +45,14 @@ def test_conda_map():
         assert pkg in data
 
 
+@pytest.mark.needs_network
 def test_iter_napari_plugin_info():
     data = iter_napari_plugin_info()
     for item in data:
         assert item
 
 
+@pytest.mark.needs_network
 def test_clear_cache():
     assert _user_agent.cache_info().hits >= 1
     cache_clear()
