Search in sources :

Example 6 with AnalysisResult

use of io.github.vocabhunter.analysis.model.AnalysisResult in project VocabHunter by VocabHunter.

the class SimpleAnalyserTest method testMixedCase.

@Test
public void testMixedCase() {
    AnalysisResult result = analyse(UPPER_CASE, LOWER_CASE);
    validate(result, use(LOWER_CASE, 2, LineReference.FIRST, LineReference.SECOND));
}
Also used : AnalysisResult(io.github.vocabhunter.analysis.model.AnalysisResult) Test(org.junit.Test)

Example 7 with AnalysisResult

use of io.github.vocabhunter.analysis.model.AnalysisResult in project VocabHunter by VocabHunter.

the class SimpleAnalyserTest method testSpanish.

@Test
public void testSpanish() {
    AnalysisResult result = analyse(LINE_WITH_ACCENTS);
    validate(result, use(SPANISH_1, 1, LineReference.FIRST), use(SPANISH_2, 1, LineReference.FIRST), use(SPANISH_4, 1, LineReference.FIRST), use(SPANISH_3, 1, LineReference.FIRST));
}
Also used : AnalysisResult(io.github.vocabhunter.analysis.model.AnalysisResult) Test(org.junit.Test)

Example 8 with AnalysisResult

use of io.github.vocabhunter.analysis.model.AnalysisResult in project VocabHunter by VocabHunter.

the class SimpleAnalyserTest method testUpperCase.

@Test
public void testUpperCase() {
    AnalysisResult result = analyse(UPPER_CASE, UPPER_CASE);
    validate(result, use(UPPER_CASE, 2, LineReference.FIRST, LineReference.SECOND));
}
Also used : AnalysisResult(io.github.vocabhunter.analysis.model.AnalysisResult) Test(org.junit.Test)

Example 9 with AnalysisResult

use of io.github.vocabhunter.analysis.model.AnalysisResult in project VocabHunter by VocabHunter.

the class SimpleAnalyserTest method testMulti.

@Test
public void testMulti() {
    AnalysisResult result = analyse(LINE_1, LINE_2);
    validate(result, use(WORD_1, 3, LineReference.FIRST, LineReference.SECOND), use(WORD_3, 2, LineReference.SECOND), use(WORD_2, 2, LineReference.FIRST));
}
Also used : AnalysisResult(io.github.vocabhunter.analysis.model.AnalysisResult) Test(org.junit.Test)

Example 10 with AnalysisResult

use of io.github.vocabhunter.analysis.model.AnalysisResult in project VocabHunter by VocabHunter.

the class SimpleAnalyserTest method testName.

@Test
public void testName() {
    AnalysisResult result = analyse();
    assertEquals("Name", NAME, result.getName());
}
Also used : AnalysisResult(io.github.vocabhunter.analysis.model.AnalysisResult) Test(org.junit.Test)

Aggregations

AnalysisResult (io.github.vocabhunter.analysis.model.AnalysisResult)14 Test (org.junit.Test)12 FileStreamer (io.github.vocabhunter.analysis.file.FileStreamer)1 WordFilter (io.github.vocabhunter.analysis.filter.WordFilter)1 SimpleAnalyser (io.github.vocabhunter.analysis.simple.SimpleAnalyser)1 Path (java.nio.file.Path)1 Duration (java.time.Duration)1 Instant (java.time.Instant)1