Skip to content

Commit

Permalink
Failing test
Browse files Browse the repository at this point in the history
  • Loading branch information
matentzn committed May 16, 2024
1 parent 91d08b8 commit 2302dde
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
15 changes: 15 additions & 0 deletions tests/data/mondo-nando.sssom.tsv
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#curie_map:
# NANDO: "http://nanbyodata.jp/ontology/NANDO_"
# MONDO: "http://purl.obolibrary.org/obo/MONDO_"
# orcid: "https://orcid.org/"
#creator_id:
# - "orcid:0000-0003-0011-764X"
# - "orcid:0000-0002-0170-9172"
#license: "https://creativecommons.org/licenses/by/4.0/"
#mapping_set_title: "NANDO - Mondo mappings provided by nanbyodata.jp"
#mapping_set_description: "This mapping set is manually curated by the NANDO team at nanbyodata.jp."
#mapping_provider: "http://nanbyodata.jp"
subject_id subject_label predicate_id object_id object_label mapping_justification
NANDO:1100001 Neuromuscular disease skos:exactMatch MONDO:0019056 neuromuscular disease semapv:MappingCuration
NANDO:1100004 Immune system disease skos:exactMatch MONDO:0005046 immune system disorder semapv:MappingCuration
NANDO:2200355 Isolated ACTH deficiency skos:exactMatch MONDO:0008720|MONDO:0016042 semapv:MappingCuration
6 changes: 6 additions & 0 deletions tests/test_validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def setUp(self) -> None:
"""Test up the test cases with the third basic example."""
self.correct_msdf1 = parse_sssom_table(f"{data_dir}/basic.tsv")
self.bad_msdf1 = parse_sssom_table(f"{data_dir}/bad_basic.tsv")
self.bad_nando = parse_sssom_table(f"{data_dir}/mondo-nando.sssom.tsv")
self.validation_types = DEFAULT_VALIDATION_TYPES
self.shacl_validation_types = [SchemaValidationType.Shacl]

Expand Down Expand Up @@ -75,3 +76,8 @@ def test_validate_sparql(self):
self.correct_msdf1,
self.shacl_validation_types,
)

def test_validate_nando(self):
"""Test Shacl validation (Not implemented)."""
self.assertIsNone(validate(self.bad_nando, self.validation_types))
self.assertRaises(ValidationError, validate, self.bad_nando, self.validation_types)

0 comments on commit 2302dde

Please sign in to comment.