### Question:
StringUtil { public static String notNullOrEmpty(@Nullable String string) { if (string == null) { return ""; } return string; }  static String notNullOrEmpty(@Nullable String string);  }### Answer:
@Test public void stringIsNull_shouldReturnEmptyString() { String string = null; string = StringUtil.notNullOrEmpty(string); assertThat(string).isEqualTo(""); }
@Test public void stringNotNull_shouldReturnTheSameValue() { String string = "Hello"; string = StringUtil.notNullOrEmpty(string); assertThat(string).isEqualTo("Hello"); }