Skip to content

Commit

Permalink
Add additional test
Browse files Browse the repository at this point in the history
Found that something else needs to get exposed
  • Loading branch information
cthoyt committed Jun 30, 2023
1 parent a746315 commit dcda7f6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions gilda/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ def get_names(self, db, id, status=None, source=None):
status=status,
source=source)

@property
def prefix_index(self):
return self.get_grounder().prefix_index


grounder = GrounderInstance()

Expand Down
4 changes: 2 additions & 2 deletions gilda/tests/test_ner.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ def test_annotate():
full_text = \
"The protein BRAF is a kinase.\nBRAF is a gene.\nBRAF is a protein."

annotations = annotate(full_text)
annotations = gilda.annotate(full_text)
assert isinstance(annotations, list)

# Check that we get 7 annotations
Expand Down Expand Up @@ -42,7 +42,7 @@ def test_get_brat():
full_text = \
"The protein BRAF is a kinase.\nBRAF is a gene.\nBRAF is a protein."

brat_str = get_brat(annotate(full_text))
brat_str = get_brat(gilda.annotate(full_text))

assert isinstance(brat_str, str)
match_str = dedent("""
Expand Down

0 comments on commit dcda7f6

Please sign in to comment.