process.env.ignorePresence = "J";
const { statusOnFoun } = require("../out/utils/utils.js");

const get = (a, b) => statusOnFoun(null, { status: a, clientStatus: b })[1];

test("Zobrazovani spravne statusu", () => {
	expect(get("online", { desktop: "online" })).toBe("Online");
	expect(get("online", { mobile: "online" })).toBe("OnlinePhone");
	expect(get("online", { web: "idle", desktop: "online" })).toBe("Online");
	expect(get("online", { desktop: "online", mobile: "idle" })).toBe("Online");
	expect(get("online", { web: "idle", mobile: "online" })).toBe("OnlinePhone");
	expect(get("idle", { web: "idle" })).toBe("Idle");
	expect(get("dnd", { web: "dnd" })).toBe("DND");
	expect(get("offline", {})).toBe("Offline");
	expect(get("offline", null)).toBe("Offline");
});
