@Test
public void testMonthFormat() throws Exception {

    String result = DateUtils.ensureTwoDigits("2015-M1", DateIntervalType.MONTH);
    assertThat(result).isEqualTo("2015-01");
    result = DateUtils.ensureTwoDigits("2015-M12", DateIntervalType.MONTH);
    assertThat(result).isEqualTo("2015-12");
}