From 4a8a2b60019e9f959222e548561d88f5d77f5998 Mon Sep 17 00:00:00 2001 From: Matthew Honnibal Date: Fri, 4 Nov 2016 00:27:32 +0100 Subject: [PATCH] Test #595 -- Bug in lemmatization of base forms. --- spacy/tests/regression/test_issue595.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 spacy/tests/regression/test_issue595.py diff --git a/spacy/tests/regression/test_issue595.py b/spacy/tests/regression/test_issue595.py new file mode 100644 index 000000000..205d62bb1 --- /dev/null +++ b/spacy/tests/regression/test_issue595.py @@ -0,0 +1,14 @@ +import pytest + +import spacy + + +@pytest.mark.models +def test_not_lemmatize_base_forms(): + nlp = spacy.load('en', parser=False) + doc = nlp(u"Don't feed the dog") + feed = doc[2] + feed.tag_ = u'VB' + assert feed.text == u'feed' + assert feed.lemma_ == u'feed' +