2017-03-01 20:30:51 +00:00
|
|
|
# coding: utf-8
|
|
|
|
from __future__ import unicode_literals
|
|
|
|
|
|
|
|
import pytest
|
|
|
|
|
|
|
|
|
|
|
|
# Note: "chromosomes" worked previous the bug fix
|
2017-05-29 20:14:31 +00:00
|
|
|
@pytest.mark.models('en')
|
2017-11-06 16:02:17 +00:00
|
|
|
@pytest.mark.parametrize('word,lemmas', [("chromosomes", ["chromosome"]), ("endosomes", ["endosome"]), ("colocalizes", ["colocaliz", "colocalize"])])
|
2017-05-29 20:14:31 +00:00
|
|
|
def test_issue781(EN, word, lemmas):
|
|
|
|
lemmatizer = EN.Defaults.create_lemmatizer()
|
2017-11-06 16:34:50 +00:00
|
|
|
assert sorted(lemmatizer(word, 'noun', morphology={'number': 'plur'})) == sorted(lemmas)
|