### Question:
StringUtils { public static String trim(String str) { if (str != null) { str = str.replaceAll("\\n", ""); str = str.replaceAll("\\t", ""); str = str.trim(); } return str; }  static String trim(String str); static String intern(String str); static boolean checkStaticExistence(String expr, String sequence);  }### Answer:
@Test public void testTrimNewLineReplacement() { assertEquals("A string", StringUtils.trim("A \n string")); }
@Test public void testTrimTabReplacement() { assertEquals("A string", StringUtils.trim("A \t string")); }
@Test public void testTrimWhitespaceReplacement() { assertEquals("A string", StringUtils.trim(" A string ")); }
@Test public void testTrimUnmodifiedString() { assertEquals("A string", StringUtils.trim("A string")); }