mirror of
https://github.com/explosion/spaCy.git
synced 2025-07-10 16:22:29 +03:00
add test
This commit is contained in:
parent
7918fa4ef9
commit
597df5bf83
13
spacy/tests/regression/test_issue1758.py
Normal file
13
spacy/tests/regression/test_issue1758.py
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
# coding: utf-8
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
import pytest
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.mark.parametrize('text', ["would've"])
|
||||||
|
def test_issue1758(en_tokenizer, text):
|
||||||
|
"""Test that "would've" is handled by the English tokenizer exceptions."""
|
||||||
|
tokens = en_tokenizer(text)
|
||||||
|
assert len(tokens) == 2
|
||||||
|
assert tokens[0].tag_ == "MD"
|
||||||
|
assert tokens[1].lemma_ == "have"
|
Loading…
Reference in New Issue
Block a user