From 89614490fa98b807b8957f36772f52000c621752 Mon Sep 17 00:00:00 2001 From: Reid Hewitt Date: Wed, 3 Jan 2024 12:53:08 -0700 Subject: [PATCH] fix lint issues --- tests/integration/compare/test_compare_int.py | 12 ------------ tests/unit/compare/conftest.py | 1 - tests/unit/load/ckan/conftest.py | 16 +--------------- tests/unit/load/ckan/test_ckan_cud.py | 1 + 4 files changed, 2 insertions(+), 28 deletions(-) diff --git a/tests/integration/compare/test_compare_int.py b/tests/integration/compare/test_compare_int.py index 7dfd67ad..4c65d917 100644 --- a/tests/integration/compare/test_compare_int.py +++ b/tests/integration/compare/test_compare_int.py @@ -1,16 +1,4 @@ -from harvester.load import ( - create_ckan_package, - purge_ckan_package, - update_ckan_package, - dcatus_to_ckan, -) from harvester.compare import compare -from harvester.utils.json import open_json - -from pathlib import Path - -TEST_DIR = Path(__file__).parents[3] -HARVEST_SOURCES = TEST_DIR / "harvest-sources" def test_compare(data_sources): diff --git a/tests/unit/compare/conftest.py b/tests/unit/compare/conftest.py index cffbd863..a104793a 100644 --- a/tests/unit/compare/conftest.py +++ b/tests/unit/compare/conftest.py @@ -1,6 +1,5 @@ import pytest from pathlib import Path -import json from harvester.utils.json import open_json from harvester.utils.util import sort_dataset, dataset_to_hash diff --git a/tests/unit/load/ckan/conftest.py b/tests/unit/load/ckan/conftest.py index 57d5826b..c6067abc 100644 --- a/tests/unit/load/ckan/conftest.py +++ b/tests/unit/load/ckan/conftest.py @@ -1,26 +1,12 @@ -import os from pathlib import Path - import pytest - -from harvester.load import create_ckan_entrypoint, dcatus_to_ckan +from harvester.load import dcatus_to_ckan from harvester.utils.json import open_json TEST_DIR = Path(__file__).parents[3] HARVEST_SOURCES = TEST_DIR / "harvest-sources" -# @pytest.fixture -# def ckan_entrypoint(): -# catalog_dev_api_key = os.getenv("CKAN_API_TOKEN_DEV") # gha -# if catalog_dev_api_key is None: # local -# import credentials - -# catalog_dev_api_key = credentials.ckan_catalog_dev_api_key - -# return create_ckan_entrypoint("https://catalog-dev.data.gov/", catalog_dev_api_key) - - @pytest.fixture def test_ckan_package_id(): return "e875348b-a7c3-47eb-b0c3-168d978b0c0f" diff --git a/tests/unit/load/ckan/test_ckan_cud.py b/tests/unit/load/ckan/test_ckan_cud.py index daaffee8..ec0b9d94 100644 --- a/tests/unit/load/ckan/test_ckan_cud.py +++ b/tests/unit/load/ckan/test_ckan_cud.py @@ -6,6 +6,7 @@ def test_dcatus_to_ckan_transform(test_dcatus_catalog): + # ruff: noqa: E501 expected_result = { "name": "fdic-failed-bank-list", "owner_org": "test",