(overrides: Partial<IUser> = {})
| 5 | import { displayName } from "./display-name"; |
| 6 | |
| 7 | function user(overrides: Partial<IUser> = {}): IUser { |
| 8 | return { |
| 9 | id: "u1", |
| 10 | email: "person@example.com", |
| 11 | firstName: "", |
| 12 | lastName: "", |
| 13 | emailVerified: true, |
| 14 | createdAt: "2026-01-01", |
| 15 | updatedAt: "2026-01-01", |
| 16 | ...overrides |
| 17 | }; |
| 18 | } |
| 19 | |
| 20 | describe("displayName", () => { |
| 21 | it("returns first + last when both are set", () => { |