ds4/spec/localization/localization.spec.ts

18 lines
620 B
TypeScript

// SPDX-FileCopyrightText: 2021 Johannes Loher
//
// SPDX-License-Identifier: MIT
import * as fs from "fs-extra";
import * as path from "path";
describe("English and german localization files", () => {
const localizationPath = "./src/lang/";
const en: Record<string, unknown> = fs.readJSONSync(path.join(localizationPath, "en.json"));
const de: Record<string, unknown> = fs.readJSONSync(path.join(localizationPath, "de.json"));
it("should have the same keys.", () => {
const deKeys = Object.keys(de);
const enKeys = Object.keys(en);
expect(deKeys).toEqual(enKeys);
});
});