Skip to content

Commit

Permalink
Refactor tests to use utils load func
Browse files Browse the repository at this point in the history
  • Loading branch information
sea-shunned committed Dec 4, 2023
1 parent cc58d92 commit 38bb8d3
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions tests/test_jsons.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,10 @@
from pydantic import ValidationError
import pytest

from aiod_registry import ModelManifest
from aiod_registry import ModelManifest, get_manifest_paths


def get_jsons():
json_dir = Path(__file__).parent.parent / "aiod_registry" / "manifests"
print(json_dir)
return json_dir.glob("*.json")


@pytest.mark.parametrize("json_path", get_jsons())
@pytest.mark.parametrize("json_path", get_manifest_paths())
def test_manifest(json_path):
with open(json_path, "r") as f:
json_manifest = json.load(f)
Expand Down

0 comments on commit 38bb8d3

Please sign in to comment.