Skip to content

Commit

Permalink
#5706 Update text for keys expiration date popup (#5712)
Browse files Browse the repository at this point in the history
* fix: update text for keys expiration date popup

* fix: test

* fix: pr reviews
  • Loading branch information
ioanmo226 authored May 14, 2024
1 parent e9c7694 commit cfe8276
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ export const contentScriptSetupIfVacant = async (webmailSpecific: WebmailSpecifi
}
warningMsg =
expirationText +
`To receive the latest keys, please ensure that you can connect to your corporate network either through VPN or in person and reload Gmail.<br/>` +
`To receive the latest keys, please ensure that you are connected to your corporate network (or through VPN) and have entered your FlowCrypt passphrase. Then reload Gmail.<br/>` +
`If this notification still shows after that, please contact your Help Desk.`;
} else {
let expirationText: string;
Expand Down
4 changes: 2 additions & 2 deletions test/source/tests/setup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -859,7 +859,7 @@ AN8G3r5Htj8olot+jm9mIa5XLXWzMNUZgg==
const gmailPage = await openMockGmailPage(t, browser, acctEmail);
// Check if notification presents
let warningMsg =
'Your local keys are expired.\nTo receive the latest keys, please ensure that you can connect to your corporate network either through VPN or in person and reload Gmail.\nIf this notification still shows after that, please contact your Help Desk.';
'Your local keys are expired.\nTo receive the latest keys, please ensure that you are connected to your corporate network (or through VPN) and have entered your FlowCrypt passphrase. Then reload Gmail.\nIf this notification still shows after that, please contact your Help Desk.';
await gmailPage.waitForContent('@webmail-notification-notify_expiring_keys', warningMsg);
// Generate expired key(positive expiration) and check if it shows correct note
const key = await opgp.generateKey({
Expand All @@ -875,7 +875,7 @@ AN8G3r5Htj8olot+jm9mIa5XLXWzMNUZgg==
await Util.sleep(1);
// Check if notification presents
warningMsg =
'Your local keys expire in 18 days.\nTo receive the latest keys, please ensure that you can connect to your corporate network either through VPN or in person and reload Gmail.\nIf this notification still shows after that, please contact your Help Desk.';
'Your local keys expire in 18 days.\nTo receive the latest keys, please ensure that you are connected to your corporate network (or through VPN) and have entered your FlowCrypt passphrase. Then reload Gmail.\nIf this notification still shows after that, please contact your Help Desk.';
await gmailPage.waitForContent('@webmail-notification-notify_expiring_keys', warningMsg);
// Check if warning message still presents when EKM returns error
t.context.mockApi!.configProvider.config.ekm!.returnError = new HttpClientErr('RequestTimeout', Status.BAD_REQUEST);
Expand Down

0 comments on commit cfe8276

Please sign in to comment.