Skip to content

Commit f4bf8a9

Browse files
committed
Mark as online tests that are online
We were missing some Signed-off-by: Philippe Ombredanne <pombredanne@nexb.com>
1 parent 94fd2c8 commit f4bf8a9

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

tests/test_api.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
test_env.test_data_dir = os.path.join(os.path.dirname(__file__), "data")
2222

2323

24+
@pytest.mark.online
2425
def test_api_with_specifier():
2526
expected_file = test_env.get_test_loc("test-api-expected.json", must_exist=False)
2627
results = resolver_api(
@@ -31,6 +32,7 @@ def test_api_with_specifier():
3132
check_data_results(results=results.to_dict(generic_paths=True), expected_file=expected_file)
3233

3334

35+
@pytest.mark.online
3436
def test_api_with_specifier_pdt():
3537
expected_file = test_env.get_test_loc("test-api-pdt-expected.json", must_exist=False)
3638
results = resolver_api(
@@ -41,7 +43,7 @@ def test_api_with_specifier_pdt():
4143
)
4244
check_data_results(results=results.to_dict(generic_paths=True), expected_file=expected_file)
4345

44-
46+
@pytest.mark.online
4547
def test_api_with_requirement_file():
4648
expected_file = test_env.get_test_loc("test-api-with-requirement-file.json", must_exist=False)
4749
results = resolver_api(
@@ -52,6 +54,7 @@ def test_api_with_requirement_file():
5254
check_data_results(results=results.to_dict(generic_paths=True), expected_file=expected_file)
5355

5456

57+
@pytest.mark.online
5558
def test_api_with_prefer_source():
5659
expected_file = test_env.get_test_loc("test-api-with-prefer-source.json", must_exist=False)
5760
results = resolver_api(
@@ -63,6 +66,7 @@ def test_api_with_prefer_source():
6366
check_data_results(results=results.to_dict(generic_paths=True), expected_file=expected_file)
6467

6568

69+
@pytest.mark.online
6670
def test_api_with_recursive_requirement_file():
6771
requirement_file = test_env.get_test_loc("recursive_requirements/r.txt")
6872
expected_file = test_env.get_test_loc(
@@ -96,6 +100,7 @@ def test_api_with_wrong_pyver():
96100
resolver_api(specifiers=["flask==2.1.2"], python_version="3.14", operating_system="linux")
97101

98102

103+
@pytest.mark.online
99104
def test_api_with_python_311():
100105
expected_file = test_env.get_test_loc("test-api-with-python-311.json", must_exist=False)
101106
results = resolver_api(
@@ -107,6 +112,7 @@ def test_api_with_python_311():
107112
check_data_results(results=results.to_dict(generic_paths=True), expected_file=expected_file)
108113

109114

115+
@pytest.mark.online
110116
def test_api_with_lief_python_312():
111117
expected_file = test_env.get_test_loc("test-api-with-lief-python-312.json", must_exist=False)
112118
results = resolver_api(
@@ -118,6 +124,7 @@ def test_api_with_lief_python_312():
118124
check_data_results(results=results.to_dict(generic_paths=True), expected_file=expected_file)
119125

120126

127+
@pytest.mark.online
121128
def test_api_with_partial_setup_py():
122129
expected_file = test_env.get_test_loc("test-api-with-partial-setup-py.json", must_exist=False)
123130
results = resolver_api(

tests/test_utils.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
from python_inspector.utils import get_netrc_auth
2323
from python_inspector.utils_pypi import PypiSimpleRepository
2424
from python_inspector.utils_pypi import valid_python_version
25+
import pytest
2526

2627
test_env = FileDrivenTesting()
2728
test_env.test_data_dir = os.path.join(os.path.dirname(__file__), "data")
@@ -83,6 +84,7 @@ def test_parse_reqs():
8384
check_json_file_results(result_file, expected_file)
8485

8586

87+
@pytest.mark.online
8688
def test_get_sdist_file():
8789
sdist_file = fetch_and_extract_sdist(
8890
repos=tuple([PypiSimpleRepository()]),

0 commit comments

Comments
 (0)