### Question:
StringUtils { public static List<String> strToList(String str, String delimiter) { if (str == null || str.isEmpty()) { return Collections.emptyList(); } List<String> stringList = new ArrayList<>(); for (String s : str.split(delimiter)) { stringList.add(s.trim()); } return stringList; }  static boolean isEmpty(String str); static boolean isSameStr(String a, String b); static String setToStr(Set<String> stringSet, String delimiter); static String setToStr(Set<String> stringSet, String delimiter, String defaultRet); static Set<String> strToSet(String str, String delimiter); static List<String> strToList(String str, String delimiter); static boolean startWithToLowerCase(String thisString, String anotherString); static final String EMPTY_STRING; static final int CHAR_A; static final int CHAR_Z; static final int CASE_GAP; }### Answer:
@Test public void testStrToList() { List<String> list = StringUtils.strToList("ab,ba,cb", ","); Assert.assertTrue(list.size() == 3); Assert.assertTrue(list.get(0).equals("ab")); Assert.assertTrue(list.get(1).equals("ba")); Assert.assertTrue(list.get(2).equals("cb")); }