1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
From 9502cb3b5e43a787a16bc2f63ec34c69f9b151c6 Mon Sep 17 00:00:00 2001
From: Tom Aarsen <Cubiegamedev@gmail.com>
Date: Tue, 19 Oct 2021 16:49:36 +0200
Subject: [PATCH] Skip doctest for printing out stopword languages
People with outdated nltk_data will fail these tests, and this test is very vulnerable to updates in nltk_data
---
nltk/test/corpus.doctest | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/nltk/test/corpus.doctest b/nltk/test/corpus.doctest
index 536ef452f..47a6fea2f 100644
--- a/nltk/test/corpus.doctest
+++ b/nltk/test/corpus.doctest
@@ -385,8 +385,8 @@ examples illustrate the use of the wordlist corpora:
>>> words.words('en')
['A', 'a', 'aa', 'aal', 'aalii', 'aam', 'Aani', 'aardvark', 'aardwolf', ...]
- >>> stopwords.fileids()
- ['arabic', 'azerbaijani', 'danish', 'dutch', 'english', 'finnish', 'french', ...]
+ >>> stopwords.fileids() # doctest: +SKIP
+ ['arabic', 'azerbaijani', 'bengali', 'danish', 'dutch', 'english', 'finnish', 'french', ...]
>>> sorted(stopwords.words('portuguese'))
['a', 'ao', 'aos', 'aquela', 'aquelas', 'aquele', 'aqueles', ...]
>>> names.fileids()
--
2.34.1
|