@Test
public void truncateShouldProperlyTruncateStringWithLengthGreaterThanMaximumLength() {

    String str = "This is the string";
    assertThat(StringUtil.truncate(str, str.length() - 1), is("This is the st..."));
    assertThat(StringUtil.truncate(str, str.length() - 1, null), is("This is the st..."));
    assertThat(StringUtil.truncate(str, str.length() - 1, "X"), is("This is the striX"));
}