add: additional test case for fillabe primary field

This commit is contained in:
2026-09-22 20:57:19 +05:30
parent 2c4297764f
commit f235ab2f29
@@ -64,3 +64,23 @@ describe("[data] PrimaryField", async () => {
});
});
});
describe("[data] PrimaryField (fillable)", async () => {
const field = new PrimaryField("primary", { fillable: true });
test("isFillable", async () => {
expect(field.isFillable()).toBe(true);
});
test("transformPersist/Retrieve", async () => {
expect(field.transformPersist(null)).resolves.toBeUndefined();
expect(field.transformRetrieve(1)).toBe(1);
});
test("format", () => {
const uuid = new PrimaryField("integer", { format: "uuid" });
expect(uuid.transformPersist(null)).toBeDefined();
});
});