Search in sources :

Example 1 with DetectHoles

use of annis.visualizers.iframe.partitur.DetectHoles in project ANNIS by korpling.

the class DetectHolesTest method testGetLeftBorder.

/**
 * Test of getLeftBorder method, of class DetectHoles.
 */
@Test
public void testGetLeftBorder() {
    System.out.println("getLeftBorder");
    DetectHoles instance = new DetectHoles(token);
    AnnisNode result = instance.getLeftBorder(node1);
    assertEquals(token.get(0), result);
    result = instance.getLeftBorder(node2);
    assertEquals(token.get(3), result);
    result = instance.getLeftBorder(node3);
    assertEquals(token.get(0), result);
    result = instance.getRightBorder(node4);
    assertEquals(token.get(5), result);
}
Also used : DetectHoles(annis.visualizers.iframe.partitur.DetectHoles) AnnisNode(annis.model.AnnisNode) Test(org.junit.Test)

Example 2 with DetectHoles

use of annis.visualizers.iframe.partitur.DetectHoles in project ANNIS by korpling.

the class DetectHolesTest method testGetRightBorder.

/**
 * Test of getRightBorder method, of class DetectHoles.
 */
@Test
public void testGetRightBorder() {
    System.out.println("getRightBorder");
    AnnisNode result = null;
    DetectHoles instance = new DetectHoles(token);
    result = instance.getRightBorder(node1);
    assertEquals(token.get(2), result);
    result = instance.getRightBorder(node2);
    assertEquals(token.get(5), result);
    result = instance.getRightBorder(node3);
    assertEquals(token.get(6), result);
    result = instance.getRightBorder(node4);
    assertEquals(token.get(5), result);
}
Also used : DetectHoles(annis.visualizers.iframe.partitur.DetectHoles) AnnisNode(annis.model.AnnisNode) Test(org.junit.Test)

Aggregations

AnnisNode (annis.model.AnnisNode)2 DetectHoles (annis.visualizers.iframe.partitur.DetectHoles)2 Test (org.junit.Test)2