@Test
public void test_partial_distance() {
String s = "country";
String t = "cougary";
LevenshteinDistance ld = new LevenshteinDistance(s);
ld.appendToTarget('c');
ld.updateDist();
assertEquals(0, ld.partialDistance());
assertEquals(6, ld.distance());
ld.appendToTarget('o');
ld.updateDist();
assertEquals(0, ld.partialDistance());
assertEquals(5, ld.distance());
ld.appendToTarget('u');
ld.updateDist();
assertEquals(0, ld.partialDistance());
assertEquals(4, ld.distance());
ld.appendToTarget('g');
ld.updateDist();
assertEquals(1, ld.partialDistance());
assertEquals(4, ld.distance());
ld.appendToTarget('a');
ld.updateDist();
assertEquals(2, ld.partialDistance());
assertEquals(4, ld.distance());
ld.appendToTarget('r');
ld.updateDist();
assertEquals(2, ld.partialDistance());
assertEquals(3, ld.distance());
ld.appendToTarget('y');
ld.updateDist();
assertEquals(2, ld.partialDistance());
assertEquals(2, ld.distance());
}