Schedule dehydration on reload if the dehydration key is already cached locally (#29021)
* Schedule dehydration on reload * fix test and use the right function to check dehydration is enabled * use dehydration helper function when scheduling dehydration on restart * fix test by passing in client object
This commit is contained in:
@@ -128,6 +128,7 @@ describe("<MatrixChat />", () => {
|
||||
getCrypto: jest.fn().mockReturnValue({
|
||||
getVerificationRequestsToDeviceInProgress: jest.fn().mockReturnValue([]),
|
||||
isCrossSigningReady: jest.fn().mockReturnValue(false),
|
||||
isDehydrationSupported: jest.fn().mockReturnValue(false),
|
||||
getUserDeviceInfo: jest.fn().mockReturnValue(new Map()),
|
||||
getUserVerificationStatus: jest.fn().mockResolvedValue(new UserVerificationStatus(false, false, false)),
|
||||
getVersion: jest.fn().mockReturnValue("1"),
|
||||
@@ -1005,6 +1006,7 @@ describe("<MatrixChat />", () => {
|
||||
resetKeyBackup: jest.fn(),
|
||||
isEncryptionEnabledInRoom: jest.fn().mockResolvedValue(false),
|
||||
checkKeyBackupAndEnable: jest.fn().mockResolvedValue(null),
|
||||
isDehydrationSupported: jest.fn().mockReturnValue(false),
|
||||
};
|
||||
loginClient.getCrypto.mockReturnValue(mockCrypto as any);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user