summaryrefslogtreecommitdiff
path: root/test/java
diff options
context:
space:
mode:
authorluccioman <luccioman@users.noreply.github.com>2018-02-02 10:27:36 +0100
committerluccioman <luccioman@users.noreply.github.com>2018-02-02 10:27:36 +0100
commit5a14d34a7dd07cb1ce249538d4b45ee39790d785 (patch)
treeedbf73b63415ac3fa9db52b49b33de3cdb66bcc8 /test/java
parent58b98347296d6417d59c09efdc74b0695cb35ec8 (diff)
Refactoring : documented and extracted autotagging processing functions.
Diffstat (limited to 'test/java')
-rw-r--r--test/java/net/yacy/document/TokenizerTest.java5
1 files changed, 2 insertions, 3 deletions
diff --git a/test/java/net/yacy/document/TokenizerTest.java b/test/java/net/yacy/document/TokenizerTest.java
index 23e2fbb5f..57243b2b9 100644
--- a/test/java/net/yacy/document/TokenizerTest.java
+++ b/test/java/net/yacy/document/TokenizerTest.java
@@ -1,7 +1,6 @@
package net.yacy.document;
-import java.net.MalformedURLException;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;
@@ -17,7 +16,7 @@ public class TokenizerTest {
* Test of words method, of class Tokenizer.
*/
@Test
- public void testWords() throws MalformedURLException {
+ public void testWords() {
// pos = 1 2 3 4 5 6 7 8 9 10 // 1-letter words don't count
String text = "One word is not a sentence because words are just words.";
WordCache meaningLib = new WordCache(null);
@@ -43,7 +42,7 @@ public class TokenizerTest {
*/
@Test
public void testNumberOfSentences() {
- Set<String> testText = new HashSet();
+ Set<String> testText = new HashSet<>();
// text with 5 sentences
testText.add("Sentence One. Sentence Two. Comment on this. This is sentence four! Good By................");
testText.add("Sentence One. Sentence two. Sentence 3? Sentence 4! Sentence w/o punktuation at end of text");