Skip to content

Commit

Permalink
✅ Updated tests
Browse files Browse the repository at this point in the history
Signed-off-by: Marcos Martinez <Marcos.Martinez.Galindo@ibm.com>
  • Loading branch information
marmg committed Sep 6, 2023
1 parent 7e4d129 commit 96a9bb0
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions zshot/tests/linker/test_blinker_linker.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import gc
import logging
import pkgutil

import pytest
import spacy
Expand All @@ -18,6 +19,7 @@ def teardown():
gc.collect()


@pytest.mark.skipif(not pkgutil.find_loader("blink"), "BLINK is not installed")
def test_blink():
linker = LinkerBlink()
with pytest.raises(Exception):
Expand All @@ -28,15 +30,15 @@ def test_blink():
assert linker.local_name2wikipedia_url('IBM').startswith("https://en.wikipedia.org/wiki")


@pytest.mark.skip()
@pytest.mark.skip(reason="Too expensive to run on every commit")
def test_blink_download():
linker = LinkerBlink()
linker.load_models()
assert isinstance(linker, Linker)
del linker.tokenizer, linker.model, linker


@pytest.mark.skip()
@pytest.mark.skip(reason="Too expensive to run on every commit")
def test_blink_linker():
nlp = spacy.blank("en")
blink_config = PipelineConfig(
Expand All @@ -55,7 +57,7 @@ def test_blink_linker():
del doc, nlp, blink_config


@pytest.mark.skip()
@pytest.mark.skip(reason="Too expensive to run on every commit")
def test_blink_linker_no_entities():
nlp = spacy.blank("en")
blink_config = PipelineConfig(
Expand Down

0 comments on commit 96a9bb0

Please sign in to comment.