Skip to content

Commit dff9471

Browse files
committed
Rename from filtering to artifacts
1 parent 9add425 commit dff9471

5 files changed

Lines changed: 12 additions & 12 deletions

File tree

opensyndrome/cli.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
generate_machine_readable_format,
1313
generate_human_readable_format,
1414
)
15-
from opensyndrome.filtering import get_schema_filepath, get_definition_dir
15+
from opensyndrome.artifacts import get_schema_filepath, get_definition_dir
1616
from opensyndrome.validators import validate_machine_readable_format
1717

1818

opensyndrome/converters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
from dotenv import load_dotenv
99
from ollama import chat
1010

11-
from opensyndrome.filtering import get_schema_filepath
11+
from opensyndrome.artifacts import get_schema_filepath
1212
from opensyndrome.schema import OpenSyndromeCaseDefinitionSchema
1313

1414
load_dotenv()

opensyndrome/validators.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import jsonschema
55
from dotenv import load_dotenv
66

7-
from opensyndrome.filtering import get_schema_filepath
7+
from opensyndrome.artifacts import get_schema_filepath
88

99
load_dotenv()
1010

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
from unittest import mock
22
from unittest.mock import Mock, call
33

4-
from opensyndrome.filtering import (
4+
from opensyndrome.artifacts import (
55
download_definitions,
66
get_definition_dir,
77
download_schema,
88
get_schema_filepath,
99
)
1010

1111

12-
@mock.patch("opensyndrome.filtering.DEFINITIONS_DIR")
13-
@mock.patch("opensyndrome.filtering.download_definitions")
12+
@mock.patch("opensyndrome.artifacts.DEFINITIONS_DIR")
13+
@mock.patch("opensyndrome.artifacts.download_definitions")
1414
class TestGetDefinitionsDir:
1515
def test_return_definitions_dir_if_not_empty(self, mock_download, mock_dir):
1616
mock_dir.iterdir.return_value = ["schema.json", "v1/"]
@@ -32,8 +32,8 @@ def test_download_definitions_from_repo_if_dir_is_empty(
3232

3333

3434
class TestDownloadSchema:
35-
@mock.patch("opensyndrome.filtering.SCHEMA_DIR")
36-
@mock.patch("opensyndrome.filtering.requests")
35+
@mock.patch("opensyndrome.artifacts.SCHEMA_DIR")
36+
@mock.patch("opensyndrome.artifacts.requests")
3737
def test_download_schema_from_github_repo(self, mock_requests, mock_dir):
3838
response = Mock()
3939
response.json.return_value = {"version": "1.0.0"} # fake schema
@@ -45,8 +45,8 @@ def test_download_schema_from_github_repo(self, mock_requests, mock_dir):
4545
assert mock_dir.mock_calls == [call.write_text('{"version": "1.0.0"}')]
4646

4747

48-
@mock.patch("opensyndrome.filtering.SCHEMA_DIR")
49-
@mock.patch("opensyndrome.filtering.download_schema")
48+
@mock.patch("opensyndrome.artifacts.SCHEMA_DIR")
49+
@mock.patch("opensyndrome.artifacts.download_schema")
5050
class TestGetSchemaFilepath:
5151
def test_return_schema_filepath_if_exists(self, mock_download, mock_dir):
5252
mock_dir.exists.return_value = True
@@ -67,8 +67,8 @@ def test_download_schema_from_repo_if_dir_does_not_exist(
6767
assert mock_download.called is True
6868

6969

70-
@mock.patch("opensyndrome.filtering.requests")
71-
@mock.patch("opensyndrome.filtering.DEFINITIONS_DIR")
70+
@mock.patch("opensyndrome.artifacts.requests")
71+
@mock.patch("opensyndrome.artifacts.DEFINITIONS_DIR")
7272
class TestDownloadDefinitions:
7373
def test_download_definitions_recursively(self, mock_path, mock_requests):
7474
mock_response_v1 = Mock()

0 commit comments

Comments
 (0)