@Test public void createDefaultJudgmentGlobalFilter() { JudgmentGlobalFilter globalFilter = factory.createDefaultJudgmentGlobalFilter(); MonthYearRange judgmentDateRange = globalFilter.getJudgmentDateRange(); LocalDate today = new LocalDate(); assertEquals(today.getYear()-20, judgmentDateRange.getStartYear()); assertEquals(1, judgmentDateRange.getStartMonth()); assertEquals(today.getYear(), judgmentDateRange.getEndYear()); assertEquals(today.getMonthOfYear(), judgmentDateRange.getEndMonth()); }
public JudgmentGlobalFilter createDefaultJudgmentGlobalFilter() { JudgmentGlobalFilter globalFilter = new JudgmentGlobalFilter(); MonthYearRange judgmentDateRange = new MonthYearRange(); LocalDate today = new LocalDate(); judgmentDateRange.setStartYear(today.getYear() - 20); judgmentDateRange.setStartMonth(1); judgmentDateRange.setEndYear(today.getYear()); judgmentDateRange.setEndMonth(today.getMonthOfYear()); globalFilter.setJudgmentDateRange(judgmentDateRange); return globalFilter; }
DefaultJudgmentGlobalFilterFactory { public JudgmentGlobalFilter createDefaultJudgmentGlobalFilter() { JudgmentGlobalFilter globalFilter = new JudgmentGlobalFilter(); MonthYearRange judgmentDateRange = new MonthYearRange(); LocalDate today = new LocalDate(); judgmentDateRange.setStartYear(today.getYear() - 20); judgmentDateRange.setStartMonth(1); judgmentDateRange.setEndYear(today.getYear()); judgmentDateRange.setEndMonth(today.getMonthOfYear()); globalFilter.setJudgmentDateRange(judgmentDateRange); return globalFilter; } }
DefaultJudgmentGlobalFilterFactory { public JudgmentGlobalFilter createDefaultJudgmentGlobalFilter() { JudgmentGlobalFilter globalFilter = new JudgmentGlobalFilter(); MonthYearRange judgmentDateRange = new MonthYearRange(); LocalDate today = new LocalDate(); judgmentDateRange.setStartYear(today.getYear() - 20); judgmentDateRange.setStartMonth(1); judgmentDateRange.setEndYear(today.getYear()); judgmentDateRange.setEndMonth(today.getMonthOfYear()); globalFilter.setJudgmentDateRange(judgmentDateRange); return globalFilter; }  }
DefaultJudgmentGlobalFilterFactory { public JudgmentGlobalFilter createDefaultJudgmentGlobalFilter() { JudgmentGlobalFilter globalFilter = new JudgmentGlobalFilter(); MonthYearRange judgmentDateRange = new MonthYearRange(); LocalDate today = new LocalDate(); judgmentDateRange.setStartYear(today.getYear() - 20); judgmentDateRange.setStartMonth(1); judgmentDateRange.setEndYear(today.getYear()); judgmentDateRange.setEndMonth(today.getMonthOfYear()); globalFilter.setJudgmentDateRange(judgmentDateRange); return globalFilter; }  JudgmentGlobalFilter createDefaultJudgmentGlobalFilter(); }
DefaultJudgmentGlobalFilterFactory { public JudgmentGlobalFilter createDefaultJudgmentGlobalFilter() { JudgmentGlobalFilter globalFilter = new JudgmentGlobalFilter(); MonthYearRange judgmentDateRange = new MonthYearRange(); LocalDate today = new LocalDate(); judgmentDateRange.setStartYear(today.getYear() - 20); judgmentDateRange.setStartMonth(1); judgmentDateRange.setEndYear(today.getYear()); judgmentDateRange.setEndMonth(today.getMonthOfYear()); globalFilter.setJudgmentDateRange(judgmentDateRange); return globalFilter; }  JudgmentGlobalFilter createDefaultJudgmentGlobalFilter();  }