import { getDisplayTextForDurationLength } from "@/helpers/duration-length-helper";

describe("damage-length-helper.js", () => {
    it("Should return the expected duration for the appointment in hours", () => {
        // Arrange / Act
        const durationMinimum = 60;
        const durationMaximum = 120;

        const duration = getDisplayTextForDurationLength(durationMinimum, durationMaximum);

        // Assert
        expect(duration).toEqual("1 - 2 hours");
    });
    it("Should return the expected duration for the appointment in minutes", () => {
        // Arrange / Act
        const durationMinimum = 30;
        const durationMaximum = 45;

        const duration = getDisplayTextForDurationLength(durationMinimum, durationMaximum);

        // Assert
        expect(duration).toEqual("30 - 45 minutes");
    });
});
