import { describe, it, expect } from "vitest";
import { getIdFromMarker } from "./index";
describe("getIdFromMarker", () => {
    it("should generate a unique ID for a marker", () => {
        const id = getIdFromMarker(37.7749, -122.4194, "San Francisco");
        expect(id).toBe("marker-37.7749--122.4194-San%20Francisco");
    });
    it("should handle spaces in the name", () => {
        const id = getIdFromMarker(34.0522, -118.2437, "Los Angeles");
        expect(id).toBe("marker-34.0522--118.2437-Los%20Angeles");
    });
    it("should handle special characters in the name", () => {
        const id = getIdFromMarker(40.7128, -74.006, "New York City!");
        expect(id).toBe("marker-40.7128--74.006-New%20York%20City!");
    });
    it("should generate different IDs for different markers", () => {
        const id1 = getIdFromMarker(51.5074, -0.1278, "London");
        const id2 = getIdFromMarker(48.8566, 2.3522, "Paris");
        expect(id1).not.toBe(id2);
    });
    it("should generate the same ID for the same marker", () => {
        const id1 = getIdFromMarker(35.6895, 139.6917, "Tokyo");
        const id2 = getIdFromMarker(35.6895, 139.6917, "Tokyo");
        expect(id1).toBe(id2);
    });
    it("should handle negative coordinates", () => {
        const id = getIdFromMarker(-33.8688, 151.2093, "Sydney");
        expect(id).toBe("marker--33.8688-151.2093-Sydney");
    });
    it("should handle zero coordinates", () => {
        const id = getIdFromMarker(0, 0, "Null Island");
        expect(id).toBe("marker-0-0-Null%20Island");
    });
});
//# sourceMappingURL=index.test.js.map