@Test
public void testHourFormat() throws Exception {

    String result = DateUtils.ensureTwoDigits("2015-M1-D23 H3", DateIntervalType.HOUR);
    assertThat(result).isEqualTo("2015-01-23 03");
    result = DateUtils.ensureTwoDigits("2015-M11-D01 H23", DateIntervalType.HOUR);
    assertThat(result).isEqualTo("2015-11-01 23");
}