mirror of
https://github.com/explosion/spaCy.git
synced 2024-11-11 12:18:04 +03:00
17 lines
305 B
Python
17 lines
305 B
Python
from __future__ import unicode_literals
|
|
import pytest
|
|
|
|
from spacy.en import English
|
|
|
|
|
|
@pytest.fixture
|
|
def EN():
|
|
return English()
|
|
|
|
|
|
def test1(EN):
|
|
words = ['JAPAN', 'GET', 'LUCKY']
|
|
tokens = EN.tokenizer.tokens_from_list(words)
|
|
assert len(tokens) == 3
|
|
assert tokens[0].string == 'JAPAN'
|