mirror of
https://github.com/Novaloop-AG/healthchat-web.git
synced 2026-11-06 14:38:21 +00:00
test: adapt unit tests to HealthChat fork customizations
This commit is contained in:
@@ -10,9 +10,17 @@ import RequiresSettingsController from "../../../../src/settings/controllers/Req
|
||||
import { SettingLevel } from "../../../../src/settings/SettingLevel";
|
||||
import SettingsStore from "../../../../src/settings/SettingsStore";
|
||||
import MatrixClientBackedController from "../../../../src/settings/controllers/MatrixClientBackedController";
|
||||
import { Layout } from "../../../../src/settings/enums/Layout";
|
||||
import { getMockClientWithEventEmitter, mockClientMethodsServer } from "../../../test-utils";
|
||||
|
||||
describe("RequiresSettingsController", () => {
|
||||
beforeEach(async () => {
|
||||
// HealthChat changed the default "layout" to Bubble. These tests use "useCompactLayout" as a
|
||||
// sample boolean setting, but its IncompatibleController forces it to false unless layout is
|
||||
// Group, so pin the layout to Group to keep useCompactLayout effective.
|
||||
await SettingsStore.setValue("layout", null, SettingLevel.DEVICE, Layout.Group);
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
SettingsStore.reset();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user