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

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

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