Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Load doamin-battery instead of battinfo which is just an extra wrapping #745

Merged
merged 1 commit into from
Apr 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion tests/test_get_by_label.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,11 @@ def test_get_by_label_emmo(emmo: "Ontology") -> None:
assert emmo[emmo.Atom.iri] == emmo.Atom

# Load an ontology with imported sub-ontologies
# Note that this test also includes testing of loading
# ontology with catalog file directly from the web
# It is therefore not duplicated in test_load.
onto = get_ontology(
"https://raw.githubusercontent.com/BIG-MAP/BattINFO/master/battinfo.ttl"
"https://raw.githubusercontent.com/emmo-repo/domain-battery/master/battery.ttl"
).load()
assert onto.Electrolyte.prefLabel.en.first() == "Electrolyte"

Expand Down
7 changes: 2 additions & 5 deletions tests/test_load.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,8 @@ def test_load(repo_dir: "Path", testonto: "Ontology") -> None:
assert str(testonto.TestClass.prefLabel.first()) == "TestClass"

# Use catalog file when downloading from web
onto = get_ontology(
"https://raw.githubusercontent.com/BIG-MAP/BattINFO/master/"
"battinfo.ttl"
).load()
assert str(onto.Electrolyte.prefLabel.first()) == "Electrolyte"
# This is tested in test_get_by_label in which some additional tests
# are performed on labels.

with pytest.raises(
EMMOntoPyException,
Expand Down
Loading