コード例 #1
0
 @Test
 public void testMatching() throws NoSuchAlgorithmException {
   search.setMatcher(new MatcherForMd5(matchingMd5));
   int[] indexArray = search.makeIndexArray();
   wordlist.addWord("poultry");
   wordlist.addWord("outwits");
   wordlist.addWord("ants");
   indexArray[0] = 0;
   indexArray[1] = 1;
   indexArray[2] = 2;
   String probe = testPhrase.replace(" ", "");
   Assert.assertEquals(testPhrase, search.makePhrase(indexArray));
   Assert.assertTrue(search.matching(probe, indexArray));
 }