Utils { static String stringOrDefault(String candidate, String defaultString) { return (candidate != null) ? candidate : defaultString; } private  Utils();   }
@Test public void testStringOrDefault_validString() { assertEquals("string", Utils.stringOrDefault("string", "default")); }
@Test public void testStringOrDefault_nullString() { assertEquals("default", Utils.stringOrDefault(null, "default")); }