public void testCommonPrefix(){
  String returned=m_Trie.getCommonPrefix();
  assertEquals("Common prefixes differ",0,returned.length());
  String expected="this is a";
  Trie t=buildTrie(new String[]{m_Data[0],m_Data[1]});
  returned=t.getCommonPrefix();
  assertEquals("Common prefixes differ",expected.length(),returned.length());
}

public void testCommonPrefix ( ) { String returned = m_Trie . getCommonPrefix ( ) ; assertEquals ( "Common prefixes differ" , 0 , returned . length ( ) ) ; String expected = "this is a" ; Trie t = buildTrie ( new String [ ] { m_Data [ 0 ] , m_Data [ 1 ] } ) ; returned = t . getCommonPrefix ( ) ; assertEquals ( "Common prefixes differ" , expected . length ( ) , returned . length ( ) ) ; }
tests whether the common prefix is determined correctly
