Skip to content

Commit

Permalink
remove unused latest_schema_tags
Browse files Browse the repository at this point in the history
  • Loading branch information
braingram committed Feb 19, 2024
1 parent 9375e9a commit 62557a1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 17 deletions.
17 changes: 1 addition & 16 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,18 +126,6 @@ def _get_tag(schema):
return None


@pytest.fixture(scope="session")
def tag_to_schema(schemas):
result = {}
for schema in schemas:
tag = _get_tag(schema)
if tag is not None:
if tag not in result:
result[tag] = []
result[tag].append(schema)
return result


@pytest.fixture(scope="session")
def id_to_schema(schemas):
result = {}
Expand All @@ -150,7 +138,7 @@ def id_to_schema(schemas):


@pytest.fixture(scope="session")
def assert_schema_correct(tag_to_schema, id_to_schema):
def assert_schema_correct(id_to_schema):
def _assert_schema_correct(path):
__tracebackhide__ = True

Expand Down Expand Up @@ -180,9 +168,6 @@ def _assert_schema_correct(path):

assert len(id_to_schema[schema["id"]]) == 1, f"{path.name} does not have a unique id"

if "tag" in schema:
assert len(tag_to_schema[schema["tag"]]) == 1, f"{path.name} does not have a unique tag"

id_base, _ = split_id(schema["id"])
for example_id in list_example_ids(schema):
example_id_base, _ = split_id(example_id)
Expand Down
2 changes: 1 addition & 1 deletion tests/test_manifests.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@


@pytest.mark.parametrize("path", MANIFEST_PATHS)
def test_manifest(path, tag_to_schema):
def test_manifest(path):
manifest = load_yaml(path)

with asdf.config_context() as config:
Expand Down

0 comments on commit 62557a1

Please sign in to comment.