@Test public void z2UCompatibilityTest() throws IOException { String sourceResourcePath = "/com/google/myanmartools/mmgov_zawgyi_src.txt"; String goldenResourcePath = "/com/google/myanmartools/mmgov_unicode_out.txt"; BufferedReader input = new BufferedReader( new InputStreamReader( TransliterateU2Z.class.getResourceAsStream(sourceResourcePath), UTF_8)); BufferedReader golden = new BufferedReader( new InputStreamReader( TransliterateU2Z.class.getResourceAsStream(goldenResourcePath), UTF_8)); int lineNum = 0; String zLine = input.readLine(); while (zLine != null) { String convertedLine = z2U.convert(zLine); String goldenLine = golden.readLine(); assertWithMessage("Difference in line " + lineNum). that(convertedLine).isEqualTo(goldenLine); zLine = input.readLine(); lineNum ++; } }
public String convert(CharSequence inString) { return runAllPhases(inString.toString()); }
Transliterate { public String convert(CharSequence inString) { return runAllPhases(inString.toString()); } }
Transliterate { public String convert(CharSequence inString) { return runAllPhases(inString.toString()); } Transliterate(String id); }
Transliterate { public String convert(CharSequence inString) { return runAllPhases(inString.toString()); } Transliterate(String id); @Override String toString(); String convert(CharSequence inString); }
Transliterate { public String convert(CharSequence inString) { return runAllPhases(inString.toString()); } Transliterate(String id); @Override String toString(); String convert(CharSequence inString);  }