use of com.djrapitops.plan.delivery.formatting.time.TimeAmountFormatter in project Plan by plan-player-analytics.
the class TimeAmountFormatterExtraZerosTest method setUpFormatter.
@BeforeAll
static void setUpFormatter() {
PlanConfig config = Mockito.mock(PlanConfig.class);
when(config.get(FormatSettings.YEAR)).thenReturn("1 year, ");
when(config.get(FormatSettings.YEARS)).thenReturn("%years% years, ");
when(config.get(FormatSettings.MONTH)).thenReturn("1 month, ");
when(config.get(FormatSettings.MONTHS)).thenReturn("%months% months, ");
when(config.get(FormatSettings.DAY)).thenReturn("1d ");
when(config.get(FormatSettings.DAYS)).thenReturn("%days%d ");
when(config.get(FormatSettings.HOURS)).thenReturn("%zero%%hours%:");
when(config.get(FormatSettings.MINUTES)).thenReturn("%hours%%zero%%minutes%:");
when(config.get(FormatSettings.SECONDS)).thenReturn("%minutes%%zero%%seconds%");
when(config.get(FormatSettings.ZERO_SECONDS)).thenReturn("00:00:00");
underTest = new TimeAmountFormatter(config);
}
use of com.djrapitops.plan.delivery.formatting.time.TimeAmountFormatter in project Plan by plan-player-analytics.
the class TimeAmountFormatterDefaultTest method setUpFormatter.
@BeforeAll
static void setUpFormatter() {
PlanConfig config = Mockito.mock(PlanConfig.class);
when(config.get(FormatSettings.YEAR)).thenReturn("1 year, ");
when(config.get(FormatSettings.YEARS)).thenReturn("%years% years, ");
when(config.get(FormatSettings.MONTH)).thenReturn("1 month, ");
when(config.get(FormatSettings.YEAR)).thenReturn("1 year, ");
when(config.get(FormatSettings.MONTH)).thenReturn("1 month, ");
when(config.get(FormatSettings.MONTHS)).thenReturn("%months% months, ");
when(config.get(FormatSettings.DAY)).thenReturn("1d ");
when(config.get(FormatSettings.DAYS)).thenReturn("%days%d ");
when(config.get(FormatSettings.HOURS)).thenReturn("%hours%h ");
when(config.get(FormatSettings.MINUTES)).thenReturn("%minutes%m ");
when(config.get(FormatSettings.SECONDS)).thenReturn("%seconds%s");
when(config.get(FormatSettings.ZERO_SECONDS)).thenReturn("0s");
underTest = new TimeAmountFormatter(config);
}
Aggregations