Skip to content
This repository has been archived by the owner on Oct 10, 2024. It is now read-only.

Commit

Permalink
github ci fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Paige Gulley committed Dec 14, 2023
1 parent 90f29f9 commit b5ac8b5
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
6 changes: 1 addition & 5 deletions mcnews/searchapi.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,11 @@
import requests
import ciso8601
from mcnews import util
import os
import pytest

VERSION = "v1" # the API access URL is versioned for future compatability and maintenance

VERSION = "v1" # the API access URL is versioned for future compatability and maintenance

IN_GITHUB_CI_WORKFLOW = os.getenv("GITHUB_ACTIONS") == "true"

pytest.mark.skipif(IN_GITHUB_CI_WORKFLOW, reason="requires VPN tunnel to Media Cloud")
class SearchApiClient:

API_BASE_URL = "https://news-search-api.tarbell.mediacloud.org/{}/".format(VERSION)
Expand Down
5 changes: 4 additions & 1 deletion mcnews/tests/test_fixtures.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
from unittest import TestCase
import datetime as dt

import os
import pytest
import mcnews.searchapi as searchapi

INTEGRATION_TEST_COLLECTION = "mediacloud_test"
INTEGRATION_TEST_HOST = "http://127.0.0.1:8000"

IN_GITHUB_CI_WORKFLOW = os.getenv("GITHUB_ACTIONS") == "true"

pytest.mark.skipif(IN_GITHUB_CI_WORKFLOW, reason="requires VPN tunnel to Media Cloud")
class TestMediaCloudCollection(TestCase):

def setUp(self) -> None:
Expand Down
4 changes: 4 additions & 0 deletions mcnews/tests/test_waybacknews.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,16 @@
import datetime as dt
import ciso8601
import requests
import os
import pytest

from mcnews.searchapi import SearchApiClient

COLLECTION_MEDIACLOUD = "mediacloud"

IN_GITHUB_CI_WORKFLOW = os.getenv("GITHUB_ACTIONS") == "true"

pytest.mark.skipif(IN_GITHUB_CI_WORKFLOW, reason="requires VPN tunnel to Media Cloud")
class TestMediaCloudCollection(TestCase):

def setUp(self) -> None:
Expand Down

0 comments on commit b5ac8b5

Please sign in to comment.