Track HiveGrid Cloud planning reference

This commit is contained in:
david committed 2026-06-26 20:48:01 +02:00
1 parent b3d5ea6764
commit e341c5938a
5784 files changed
+1104929 -3

No files matched your search

@@ -0,0 +1,26 @@
import fs from "node:fs";
import path from "node:path";
import { describe, expect, it } from "vitest";
import { defaultThemes } from "./defaultThemes";
const repoRoot = process.cwd();
function readSettings(locale: "de" | "en") {
return JSON.parse(fs.readFileSync(path.join(repoRoot, `apps/web/public/locales/${locale}/settings.json`), "utf8")) as Record<string, string>;
}
describe("default theme preset i18n", () => {
it("keeps every visible preset label backed by English and German settings keys", () => {
const en = readSettings("en");
const de = readSettings("de");
for (const theme of defaultThemes) {
expect(theme.labelKey).toBe(`settings:tenant.theme.presets.${theme.value}`);
const localeKey = theme.labelKey.replace("settings:", "");
expect(en[localeKey], `${theme.value} English label`).toBeTruthy();
expect(de[localeKey], `${theme.value} German label`).toBeTruthy();
}
});
});