Skip to content

Commit

Permalink
Make internet archive tests optional
Browse files Browse the repository at this point in the history
  • Loading branch information
palewire committed Nov 20, 2022
1 parent f4a5f81 commit c743037
Show file tree
Hide file tree
Showing 5 changed files with 82 additions and 72 deletions.
1 change: 1 addition & 0 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ twine = "*"
xlwt = "*"
pytest-env = "*"
pytest-cov = "*"
pytest-optional-tests = "*"

[requires]
python_version = "3.9"
146 changes: 74 additions & 72 deletions Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[pytest]
optional_tests:
internetarchive: Internet Arhive tests that ping the archive.org API
2 changes: 2 additions & 0 deletions tests/test_extract.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import pytest
from click.testing import CliRunner

from newshomepages.extract import cli


@pytest.mark.internetarchive
def test_extract_item(tmp_path):
"""Test a site's item download."""
runner = CliRunner()
Expand Down
2 changes: 2 additions & 0 deletions tests/test_wayback.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import pytest
from click.testing import CliRunner

from newshomepages import wayback


@pytest.mark.internetarchive
def test_wayback_cli(tmp_path):
"""Test a single wayback archive request."""
runner = CliRunner()
Expand Down

0 comments on commit c743037

Please sign in to comment.