public List<TimerangePreset> convert(final Map<Period, String> timerangeOptions) {
        if (timerangeOptions == null) {
            return List.of();
        }
        return timerangeOptions.entrySet()
                .stream()
                .map(entry -> new TimerangePreset(
                        periodConverter.apply(entry.getKey()),
                        entry.getValue())
                )
                .collect(Collectors.toList());
    }
@Test
    void testConversionOnSomeDefaultRelativeTimerangeOptions() {
        Map<Period, String> defaults = new LinkedHashMap(
                Map.of(
                        Period.minutes(15), "15 minutes",
                        Period.hours(8), "8 hours",
                        Period.days(1), "1 day"
                )
        );

        doCallRealMethod().when(periodConverter).apply(any(Period.class));
        final List<TimerangePreset> result = toTest.convert(defaults);

        assertThat(result)
                .isNotNull()
                .hasSize(3)
                .extracting(TimerangePreset::timeRange, TimerangePreset::description)
                .containsExactlyInAnyOrder(
                        tuple(RelativeRange.Builder.builder()
                                .from(15 * 60)
                                .build(), "15 minutes"),
                        tuple(RelativeRange.Builder.builder()
                                .from(8 * 60 * 60)
                                .build(), "8 hours"),
                        tuple(RelativeRange.Builder.builder()
                                .from(24 * 60 * 60)
                                .build(), "1 day")
                );

    }