BAEL-5465: removed link from readme, reordered tests (#11977)
This commit is contained in:
@@ -13,6 +13,17 @@ import org.junit.Test;
|
||||
|
||||
public class SubtractDaysFromDateUnitTest {
|
||||
|
||||
@Test
|
||||
public void givenLocalDateTime_whenSubtractingFiveDays_dateIsChangedCorrectly() {
|
||||
LocalDate localDateTime = LocalDate.of(2022, 4, 20);
|
||||
|
||||
localDateTime = localDateTime.minusDays(5);
|
||||
|
||||
assertEquals(15, localDateTime.getDayOfMonth());
|
||||
assertEquals(4, localDateTime.getMonthValue());
|
||||
assertEquals(2022, localDateTime.getYear());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void givenCalendarDate_whenSubtractingFiveDays_dateIsChangedCorrectly() {
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
@@ -35,15 +46,4 @@ public class SubtractDaysFromDateUnitTest {
|
||||
assertEquals(4, dateTime.getMonthOfYear());
|
||||
assertEquals(2022, dateTime.getYear());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void givenLocalDateTime_whenSubtractingFiveDays_dateIsChangedCorrectly() {
|
||||
LocalDate localDateTime = LocalDate.of(2022, 4, 20);
|
||||
|
||||
localDateTime = localDateTime.minusDays(5);
|
||||
|
||||
assertEquals(15, localDateTime.getDayOfMonth());
|
||||
assertEquals(4, localDateTime.getMonthValue());
|
||||
assertEquals(2022, localDateTime.getYear());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user