From be5541bd16a84c37b973cf77cb0f4d5c5e83e39a Mon Sep 17 00:00:00 2001 From: ines Date: Mon, 8 May 2017 16:20:14 +0200 Subject: [PATCH] Fix import and tokenizer exceptions --- spacy/tests/regression/test_issue768.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/spacy/tests/regression/test_issue768.py b/spacy/tests/regression/test_issue768.py index a1701334b..ff34decba 100644 --- a/spacy/tests/regression/test_issue768.py +++ b/spacy/tests/regression/test_issue768.py @@ -3,8 +3,10 @@ from __future__ import unicode_literals from ...language import Language from ...attrs import LANG -from ...fr.language_data import get_tokenizer_exceptions, STOP_WORDS +from ...fr.stop_words import STOP_WORDS +from ...fr.tokenizer_exceptions import TOKENIZER_EXCEPTIONS from ...language_data.punctuation import TOKENIZER_INFIXES, ALPHA +from ...util import update_exc import pytest @@ -20,7 +22,7 @@ def fr_tokenizer_w_infix(): class Defaults(Language.Defaults): lex_attr_getters = dict(Language.Defaults.lex_attr_getters) lex_attr_getters[LANG] = lambda text: 'fr' - tokenizer_exceptions = get_tokenizer_exceptions() + tokenizer_exceptions = update_exc(TOKENIZER_EXCEPTIONS) stop_words = STOP_WORDS infixes = TOKENIZER_INFIXES + [SPLIT_INFIX]