465e3da40350f30c2ef965b72531fb33666fa388,tests/test_extract.py,,test_words_min_freq,#Any#,86

Before Change


    counts.update(tok.lower_ for tok in spacy_doc)
    result = [
        tok
        for tok in extract.words(
            spacy_doc,
            filter_stops=False,
            filter_punct=False,

After Change


def test_words_min_freq(spacy_doc):
    counts = collections.Counter()
    counts.update(tok.lower_ for tok in spacy_doc)
    result = list(extract.words(spacy_doc, min_freq=2))
    assert all(counts[tok.lower_] >= 2 for tok in result)


def test_ngrams_less_than_1(spacy_doc):
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: chartbeat-labs/textacy
Commit Name: 465e3da40350f30c2ef965b72531fb33666fa388
Time: 2019-03-20
Author: burtdewilde@gmail.com
File Name: tests/test_extract.py
Class Name:
Method Name: test_words_min_freq


Project Name: chartbeat-labs/textacy
Commit Name: 465e3da40350f30c2ef965b72531fb33666fa388
Time: 2019-03-20
Author: burtdewilde@gmail.com
File Name: tests/test_extract.py
Class Name:
Method Name: test_words_good_tags


Project Name: chartbeat-labs/textacy
Commit Name: 465e3da40350f30c2ef965b72531fb33666fa388
Time: 2019-03-20
Author: burtdewilde@gmail.com
File Name: tests/test_extract.py
Class Name:
Method Name: test_words