Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
cmungall committed Jun 5, 2024
1 parent 4d1f4c3 commit 53c965c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
7 changes: 4 additions & 3 deletions tests/test_implementations/test_pronto.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,18 +90,19 @@ def test_conflicting_oio_prefixes(self):
"""
See https://github.com/INCATools/ontology-access-kit/issues/702
"""
resource = OntologyResource(slug="metadata-map-prefixes-test.obo", directory=INPUT_DIR, local=True)
resource = OntologyResource(
slug="metadata-map-prefixes-test.obo", directory=INPUT_DIR, local=True
)
adapter = ProntoImplementation(resource)
m = adapter.entity_metadata_map("HP:0000001")
self.assertIsNotNone(m)
uri = "http://www.geneontology.org/formats/oboInOwl#foo"
curie = adapter.uri_to_curie(uri)
# behavior is currently intentionally undefined
assert (curie == "oio:foo" or curie == "oboInOwl:foo")
assert curie == "oio:foo" or curie == "oboInOwl:foo"
# must be reversible
assert adapter.curie_to_uri(curie) == uri


def test_relationship_map(self):
oi = self.oi
rels = oi.outgoing_relationship_map("GO:0005773")
Expand Down
6 changes: 4 additions & 2 deletions tests/test_implementations/test_simple_obo.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,14 +108,16 @@ def test_conflicting_oio_prefixes(self):
See https://github.com/INCATools/ontology-access-kit/issues/702
"""
# TODO: DRY. This is currently duplicative of a pronto test
resource = OntologyResource(slug="metadata-map-prefixes-test.obo", directory=INPUT_DIR, local=True)
resource = OntologyResource(
slug="metadata-map-prefixes-test.obo", directory=INPUT_DIR, local=True
)
adapter = SimpleOboImplementation(resource)
m = adapter.entity_metadata_map("HP:0000001")
self.assertIsNotNone(m)
uri = "http://www.geneontology.org/formats/oboInOwl#foo"
curie = adapter.uri_to_curie(uri)
# behavior is currently intentionally undefined
assert (curie == "oio:foo" or curie == "oboInOwl:foo")
assert curie == "oio:foo" or curie == "oboInOwl:foo"
# must be reversible
assert adapter.curie_to_uri(curie) == uri

Expand Down

0 comments on commit 53c965c

Please sign in to comment.