feat(ui): renk paleti, ikonlar, MoneyInput ve navigasyon

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-05 02:57:58 +03:00
parent 8dd5fd42e3
commit d2aa9d8ae2
12 changed files with 600 additions and 6 deletions
+27
View File
@@ -0,0 +1,27 @@
import mongoose from "mongoose";
import { expect } from "vitest";
import { getDb, getMongoClient } from "@/lib/db/mongo";
import { HouseholdModel } from "@/models/household";
import { runSeed } from "../../scripts/seed/run";
/** Entegrasyon testleri için: test veritabanını temizler, seed'i çalıştırır, kimlikleri döner. */
export async function setupSeededDb() {
expect(getDb().databaseName).toBe("butcem_test");
await getDb().dropDatabase();
await runSeed({ log: () => {} });
const users = new Map<string, string>();
for (const u of await getDb().collection("user").find().toArray())
users.set(String(u.username), String(u._id));
const households = new Map<string, string>();
for (const h of await HouseholdModel.find().lean()) households.set(h.name, String(h._id));
return {
user: (username: string) => users.get(username)!,
household: (name: string) => households.get(name)!,
};
}
export async function teardownDb() {
await getDb().dropDatabase();
await mongoose.disconnect();
await getMongoClient().close();
}