This commit is contained in:
Thomas Rittson 2022-06-28 12:18:06 +10:00
parent 83e0db5163
commit d9f2dc2b90
1 changed files with 3 additions and 1 deletions

View File

@ -17,7 +17,9 @@ describe("AttachmentView", () => {
attachment.fileName = "my filename";
attachment.key = "encKey" as any;
jest.spyOn(SymmetricCryptoKey, "fromJSON").mockImplementation(() => "encKeyfromJSON" as any);
jest
.spyOn(SymmetricCryptoKey, "fromJSON")
.mockImplementation((key: string) => (key + "fromJSON") as any);
const stringify = JSON.stringify(attachment);