UNPKG

@accounter/server

Version:
41 lines (40 loc) 1.48 kB
/** * Expense Scenario A: Local Currency (ILS) Receipt Expense * * This scenario represents a simple expense paid in local currency (ILS) with a receipt. * It demonstrates the basic happy path for expense recording and ledger generation. * * Flow: * 1. Admin business purchases from Local Supplier Ltd * 2. Transaction recorded: -500 ILS (negative = expense/outflow) * 3. Receipt document provided matching the transaction * 4. Expected ledger: debit expense category, credit bank account * * Prerequisites: * - Admin business entity exists (from seed) * - General expense tax category exists (from seed) */ import type { Fixture } from '../../helpers/fixture-types'; /** * Expense Scenario A: ILS Receipt Expense * * @description * A local supplier provides a service, admin pays 500 ILS, receives a receipt. * This is the simplest expense case with matching transaction and document. * * @example * ```typescript * import { expenseScenarioA } from './fixtures/expenses/expense-scenario-a'; * import { insertFixture } from './helpers/fixture-loader'; * * await withTestTransaction(pool, async (client) => { * await seedAdminCore(client); // Ensure admin context exists * const idMap = await insertFixture(client, expenseScenarioA); * * // Now test ledger generation * const chargeId = idMap.get('charge-office-supplies'); * // ... trigger ledger generation and assert * }); * ``` */ export declare const expenseScenarioA: Fixture;