import React from "react";
import { vi } from "vitest";
import { render } from "@testing-library/react";
import { Content } from "./index";
vi.mock("react-i18next", () => ({
    useTranslation: () => ({
        t: (key) => key,
    }),
}));
describe("Content", () => {
    it("renders the title and pill correctly", () => {
        const { getByTestId } = render(React.createElement(Content, { score: "pedestrian_friendly" }));
        const titleElement = getByTestId("highlight-title");
        const pillElement = getByTestId("highlight-pill");
        expect(titleElement).toHaveTextContent("highlight.title");
        expect(pillElement).toHaveTextContent("common:scores.pedestrian_friendly.title");
    });
    it("does not render the pill content when score is not provided", () => {
        const { getByTestId } = render(React.createElement(Content, null));
        const titleElement = getByTestId("highlight-title");
        const pillElement = getByTestId("highlight-pill");
        expect(titleElement).toHaveTextContent("highlight.title");
        expect(pillElement).toBeEmptyDOMElement();
    });
});
//# sourceMappingURL=index.test.js.map