Improve randomString mock for better snapshots (#11375)
This commit is contained in:
parent
c3574c2050
commit
57a0d99dc8
49 changed files with 133 additions and 256 deletions
|
@ -24,12 +24,6 @@ import { MetaSpace } from "../../../../../../src/stores/spaces";
|
|||
import { SettingLevel } from "../../../../../../src/settings/SettingLevel";
|
||||
import { flushPromises } from "../../../../../test-utils";
|
||||
|
||||
// used by checkbox to relate labels to inputs
|
||||
// make it stable for snapshot testing
|
||||
jest.mock("matrix-js-sdk/src/randomstring", () => ({
|
||||
randomString: jest.fn().mockReturnValue("abcd"),
|
||||
}));
|
||||
|
||||
describe("<SidebarUserSettingsTab />", () => {
|
||||
beforeEach(() => {
|
||||
jest.spyOn(PosthogTrackers, "trackInteraction").mockClear();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue