import { describe, it, expect } from "vitest";
import { chineseWordListCatalog } from "./index.js";

describe("chinese word lists", () => {
  it("has descriptors", () => {
    expect(chineseWordListCatalog.descriptors.length).toBeGreaterThan(0);
  });

  it("can load descriptor data", async () => {
    const descriptors = chineseWordListCatalog.getDescriptorsByExamGrade("A1");
    expect(descriptors.length).toBeGreaterThan(0);
    const data = await descriptors[0].load();
    expect(data.words).toBeDefined();
    expect(data.words.length).toBeGreaterThan(0);
  });
});
