### Question:
LeftPadder implements Padder { public String unpad(String paddedData) { int i = 0; int len = paddedData.length(); while (i < len) { if (paddedData.charAt(i) != pad) { return paddedData.substring(i); } i++; } return ""; } LeftPadder(char pad); String pad(String data, int maxLength); String unpad(String paddedData); static final LeftPadder ZERO_PADDER; }### Answer:
@Test public void testUnpad() throws Exception { assertEquals("123", padder.unpad("000123")); }
@Test public void testUnpadAllPadding() throws Exception { assertEquals("", padder.unpad("000")); }