import { describe, expect, it } from "vitest";
import {
  ORDER_GROUP_BUCKET_LABELS,
  ORDER_GROUP_DISPLAY_STATUS_OPTIONS,
  ORDER_GROUP_STATUS_LABELS,
} from "../../services/orderGroupViews";

describe("LogisticsReadinessBoard", () => {
  it("renders all group bucket labels from the model", () => {
    const bucketKeys = Object.keys(ORDER_GROUP_BUCKET_LABELS);
    expect(bucketKeys).toContain("ready_to_launch");
    expect(bucketKeys).toContain("manual_work");
    expect(bucketKeys).toContain("sms_sent");
    expect(bucketKeys).toHaveLength(3);
  });

  it("renders bucket labels in Russian", () => {
    expect(ORDER_GROUP_BUCKET_LABELS.ready_to_launch).toBe("Готовы к уведомлению");
    expect(ORDER_GROUP_BUCKET_LABELS.sms_sent).toBe("Уведомления отправлены");
    expect(ORDER_GROUP_BUCKET_LABELS.manual_work).toBe("Нужна ручная работа");
  });

  it("renders status labels in Russian", () => {
    expect(ORDER_GROUP_STATUS_LABELS.ready_for_notification).toBe("Готово к уведомлению");
    expect(ORDER_GROUP_STATUS_LABELS.sms_sent).toBe("SMS отправлены");
    expect(ORDER_GROUP_STATUS_LABELS.manual_work).toBe("Нужна ручная работа");
    expect(ORDER_GROUP_DISPLAY_STATUS_OPTIONS.map((option) => option.label)).toContain("Согласовано");
  });
});
