-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
142c791
commit 34c5b08
Showing
2 changed files
with
12 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2024 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
@@ -19,17 +19,18 @@ | |
import java.io.*; | ||
import java.net.*; | ||
|
||
import org.junit.*; | ||
import org.junit.jupiter.api.*; | ||
import static org.junit.jupiter.api.Assertions.*; | ||
|
||
import org.luwrain.core.*; | ||
|
||
@Ignore public class TaskTest extends Assert | ||
public class TaskTest | ||
{ | ||
static private final String url = "https://download.luwrain.org/pdf/presentation-HongKongOSConference-en-2015-06-27.pdf"; | ||
static private final String noSuchFileUrl = "https://download.luwrain.org/pdf/no-such-file.pdf"; | ||
static private final String noSuchHostUrl = "https://no.such.host/presentation.pdf"; | ||
|
||
@Test public void fetch() throws Exception | ||
@Disabled @Test public void fetch() throws Exception | ||
{ | ||
final TestingTaskCallback callback = new TestingTaskCallback(); | ||
final File destFile = File.createTempFile("lwriotest", ".pdf"); | ||
|
@@ -39,15 +40,15 @@ | |
assertTrue(callback.fileSize == 77249); | ||
} | ||
|
||
@Test public void noSuchFile() throws Exception | ||
@Disabled @Test public void noSuchFile() throws Exception | ||
{ | ||
final TestingTaskCallback callback = new TestingTaskCallback(); | ||
final File destFile = File.createTempFile("lwriotest", ".pdf"); | ||
final Task task = new Task(callback, new URL(noSuchFileUrl), destFile); | ||
task.startSync(); | ||
} | ||
|
||
@Test public void noSuchHost() throws Exception | ||
@Disabled @Test public void noSuchHost() throws Exception | ||
{ | ||
final TestingTaskCallback callback = new TestingTaskCallback(); | ||
final File destFile = File.createTempFile("lwriotest", ".pdf"); | ||
|
@@ -57,7 +58,4 @@ | |
assertTrue(callback.throwable != null); | ||
assertTrue(callback.throwable instanceof java.net.UnknownHostException); | ||
} | ||
|
||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2024 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
@@ -14,20 +14,17 @@ | |
General Public License for more details. | ||
*/ | ||
|
||
|
||
package org.luwrain.nlp.ru.spell; | ||
|
||
//https://languagetool.org/development/api/org/languagetool/rules/spelling/SpellingCheckRule.html | ||
|
||
|
||
import java.util.*; | ||
|
||
import org.junit.*; | ||
import org.junit.jupiter.api.*; | ||
import static org.junit.jupiter.api.Assertions.*; | ||
|
||
import org.luwrain.core.*; | ||
import org.luwrain.nlp.*; | ||
|
||
public class RuSpellCheckerTest extends Assert | ||
public class RuSpellCheckerTest | ||
{ | ||
private RuSpellChecker checker = null; | ||
|
||
|
@@ -59,7 +56,7 @@ public class RuSpellCheckerTest extends Assert | |
|
||
|
||
|
||
@Before public void create() | ||
@BeforeEach public void create() | ||
{ | ||
checker = new RuSpellChecker(); | ||
} | ||
|