Skip to content

Commit

Permalink
Prefixes should be checked against .bimap instead of .prefix_map
Browse files Browse the repository at this point in the history
  • Loading branch information
hrshdhgd committed Nov 27, 2023
1 parent 9e7a04f commit f1ffa9a
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tests/test_parsers.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,3 +410,14 @@ def test_round_trip(self):

# This checks that nothing funny gets added unexpectedly
self.assertEqual(expected_prefix_map, reconsitited_msdf.prefix_map)

def test_bimap(self):
epm = [{
"prefix": "Orphanet",
"prefix_synonyms": [
"orphanet.ordo"
],
"uri_prefix": "http://www.orpha.net/ORDO/Orphanet_" }]
converter = Converter.from_extended_prefix_map(epm)
self.assertTrue('Orphanet' in converter.bimap)
self.assertFalse('orphanet.ordo' in converter.bimap)

0 comments on commit f1ffa9a

Please sign in to comment.