@Test
public void testRightPad_StringIntChar() {

    assertEquals(null, rightPad(null, 5, ' '));
    assertEquals("     ", rightPad("", 5, ' '));
    assertEquals("abc  ", rightPad("abc", 5, ' '));
    assertEquals("abc", rightPad("abc", 2, ' '));
    assertEquals("abc", rightPad("abc", -1, ' '));
    assertEquals("abcxx", rightPad("abc", 5, 'x'));
    String str = rightPad("aaa", 10000, 'a');  // bigger than pad length
    assertEquals(10000, str.length());
}