@Test public void setLengthShouldAppendCharacterForEmptyStrings() { assertEquals(" ", StringUtil.setLength("", 10, ' ')); }
@Test public void setLengthShouldAppendCharacterForStringsThatAreTooShort() { assertEquals("This ", StringUtil.setLength("This", 10, ' ')); }
@Test public void setLengthShouldReturnStringsThatAreTheDesiredLength() { assertEquals("This is the string", StringUtil.setLength("This is the string", 18, ' ')); }
@Test public void setLengthShouldTruncateStringsThatAreTooLong() { assertEquals("This is the st", StringUtil.setLength("This is the string", 14, ' ')); }
@Test public void setLengthShouldAppendCharacterForNullStrings() { assertEquals(" ", StringUtil.setLength(null, 10, ' ')); }