### Question:
ProcessLibrary { static Encoding chooseEncoding(String s) { for (char c : s.toCharArray()) { if (c > 0xff) { return Encoding.UTF16BE; } } return Encoding.ISO88591; }  void process(File inFile, OutputStream outStr); void register(int hohmType, StringConverter cnvtr);  }### Answer:
@Test public void chooseCorrectEncoding() { ProcessLibrary.Encoding enc; enc = ProcessLibrary.chooseEncoding(""); assertEquals(ProcessLibrary.Encoding.ISO88591, enc); enc = ProcessLibrary.chooseEncoding("Test"); assertEquals(ProcessLibrary.Encoding.ISO88591, enc); enc = ProcessLibrary.chooseEncoding("T€st"); assertEquals(ProcessLibrary.Encoding.UTF16BE, enc); }