2018-04-07 17:07:28 +00:00
|
|
|
# coding: utf-8
|
|
|
|
from __future__ import unicode_literals
|
|
|
|
|
|
|
|
import pytest
|
|
|
|
|
|
|
|
|
2018-11-27 00:09:36 +00:00
|
|
|
@pytest.mark.parametrize(
|
|
|
|
"string,lemma",
|
|
|
|
[
|
|
|
|
("affaldsgruppernes", "affaldsgruppe"),
|
|
|
|
("detailhandelsstrukturernes", "detailhandelsstruktur"),
|
|
|
|
("kolesterols", "kolesterol"),
|
|
|
|
("åsyns", "åsyn"),
|
|
|
|
],
|
|
|
|
)
|
2018-07-24 21:38:44 +00:00
|
|
|
def test_da_lemmatizer_lookup_assigns(da_tokenizer, string, lemma):
|
2018-04-07 17:07:28 +00:00
|
|
|
tokens = da_tokenizer(string)
|
|
|
|
assert tokens[0].lemma_ == lemma
|