/** * Category factory functions for testing * * Provides functions to create mock categories. * * @example * ```typescript * const category = createMockCategory({ name: 'Jobs' }); * const row = createMockCategoryRow({ is_curated: 1 }); * ``` */ /** * Category database row type (as stored in D1) */ export interface CategoryRow { id: string; name: string; description: string; icon: string | null; is_curated: number; display_order: number; } /** * Category domain object (with boolean is_curated) */ export interface Category { id: string; name: string; description: string; icon: string | null; is_curated: boolean; display_order: number; } /** * Creates a mock category row (as returned from database) * * @param overrides - Optional overrides for the default values * @returns A CategoryRow object */ export declare function createMockCategoryRow(overrides?: Partial): CategoryRow; /** * Creates a mock category domain object * * @param overrides - Optional overrides for the default values * @returns A Category object */ export declare function createMockCategory(overrides?: Partial): Category; /** * Creates multiple mock categories * * @param count - Number of categories to create * @param overrides - Optional overrides to apply to all categories * @returns Array of Category objects */ export declare function createMockCategories(count: number, overrides?: Partial): Category[]; /** * Creates a curated category * * @param overrides - Optional overrides * @returns A curated Category object */ export declare function createCuratedCategory(overrides?: Partial): Category; /** * Default preset categories for testing */ export declare const DEFAULT_CATEGORIES: Category[]; /** * Converts a Category to a CategoryRow * * @param category - The Category to convert * @returns A CategoryRow object */ export declare function categoryToRow(category: Category): CategoryRow; //# sourceMappingURL=category.d.ts.map