Utils { public static final String getSubstring(String string) { if (string.contains("=")) { return string.substring(string.indexOf("=") + 1); } return null; } private  Utils(); static final String getSubstring(String string);  }
@Test public void testGetSubstring() { assertEquals("asdf", Utils.getSubstring("name=asdf")); assertEquals("asdf=asdf", Utils.getSubstring("name=asdf=asdf")); assertEquals("", Utils.getSubstring("name=")); assertNull("", Utils.getSubstring("name")); }