-
Notifications
You must be signed in to change notification settings - Fork 11
Signed-only messages not recognized as signed #1088
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
6aadba2
Signed-only messages not recognized as signed
ivan-ushakov 93f5d5c
Merge branch 'master' into feature/issue-1020
ivan-ushakov 03e0469
Merge branch 'master' into feature/issue-1020
ivan-ushakov a38e5ea
Code review fixes
ivan-ushakov 045ebc9
Merge branch 'master' into feature/issue-1020
ivan-ushakov bba5f0b
All cases now
ivan-ushakov 8d535f6
Move UI test to search approach
ivan-ushakov a644ade
Merge branch 'master' into feature/issue-1020
ivan-ushakov 10131f7
UI test fixed
ivan-ushakov File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| import BaseScreen from './base.screen'; | ||
| import ElementHelper from "../helpers/ElementHelper"; | ||
|
|
||
| const SELECTORS = { | ||
| BACK_BUTTON: '~arrow left c', | ||
| SCREEN: '~searchViewController', | ||
| SEARCH_FIELD: '~searchAllEmailField' | ||
| }; | ||
|
|
||
| class SearchScreen extends BaseScreen { | ||
| constructor() { | ||
| super(SELECTORS.SCREEN); | ||
| } | ||
|
|
||
| get backButton() { | ||
| return $(SELECTORS.BACK_BUTTON) | ||
| } | ||
|
|
||
| get searchField() { | ||
| return $(SELECTORS.SEARCH_FIELD); | ||
| } | ||
|
|
||
| clickBackButton = async () => { | ||
| await browser.pause(2000); | ||
| await ElementHelper.waitAndClick(await this.backButton); | ||
| } | ||
|
|
||
| searchAndClickEmailBySubject = async (subject: string) => { | ||
| await (await this.searchField).setValue(`subject: '${subject}'`); | ||
|
|
||
| const selector = `~${subject}`; | ||
| await ElementHelper.waitAndClick(await $(selector), 500); | ||
| } | ||
| } | ||
|
|
||
| export default new SearchScreen(); |
75 changes: 75 additions & 0 deletions
75
appium/tests/specs/inbox/CheckAllEmailSignatureCases.spec.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,75 @@ | ||
| import { | ||
| SplashScreen, | ||
| SetupKeyScreen, | ||
| MailFolderScreen, | ||
| EmailScreen, | ||
| SearchScreen | ||
| } from '../../screenobjects/all-screens'; | ||
|
|
||
| describe('INBOX: ', () => { | ||
|
|
||
| it('user is able to view correct signature badge for all cases', async () => { | ||
|
|
||
| await SplashScreen.login(); | ||
| await SetupKeyScreen.setPassPhrase(); | ||
| await MailFolderScreen.checkInboxScreen(); | ||
|
|
||
| // signed+encrypted message | ||
| await MailFolderScreen.clickSearchButton(); | ||
|
|
||
| await SearchScreen.searchAndClickEmailBySubject('Signed and encrypted message'); | ||
|
|
||
| await EmailScreen.checkEncryptionBadge('encrypted'); | ||
| await EmailScreen.checkSignatureBadge('signed'); | ||
| await EmailScreen.clickBackButton(); | ||
|
|
||
| await SearchScreen.clickBackButton(); | ||
|
|
||
| // singed only message | ||
| await MailFolderScreen.clickSearchButton(); | ||
| await SearchScreen.searchAndClickEmailBySubject('Signed only message'); | ||
|
|
||
| await EmailScreen.checkEncryptionBadge('not encrypted'); | ||
| await EmailScreen.checkSignatureBadge('signed'); | ||
| await EmailScreen.clickBackButton(); | ||
|
|
||
| await SearchScreen.clickBackButton(); | ||
|
|
||
| // signed only message with detached signature | ||
| await MailFolderScreen.clickSearchButton(); | ||
| await SearchScreen.searchAndClickEmailBySubject('Signed only message with detached signature'); | ||
|
|
||
| await EmailScreen.checkEncryptionBadge('not encrypted'); | ||
| await EmailScreen.checkSignatureBadge('signed'); | ||
| await EmailScreen.clickBackButton(); | ||
|
|
||
| await SearchScreen.clickBackButton(); | ||
|
|
||
| // plain message | ||
| await MailFolderScreen.clickSearchButton(); | ||
| await SearchScreen.searchAndClickEmailBySubject('Test 1'); | ||
|
|
||
| await EmailScreen.checkEncryptionBadge('not encrypted'); | ||
| await EmailScreen.checkSignatureBadge('not signed'); | ||
| await EmailScreen.clickBackButton(); | ||
|
|
||
| await SearchScreen.clickBackButton(); | ||
|
|
||
| // signed only message where the pubkey is not available | ||
| await MailFolderScreen.clickSearchButton(); | ||
| await SearchScreen.searchAndClickEmailBySubject('Signed only message where the pubkey is not available'); | ||
|
|
||
| await EmailScreen.checkEncryptionBadge('decrypt error'); | ||
| await EmailScreen.clickBackButton(); | ||
|
|
||
| await SearchScreen.clickBackButton(); | ||
|
|
||
| // signed only message that was tempered during transit | ||
| await MailFolderScreen.clickSearchButton(); | ||
| await SearchScreen.searchAndClickEmailBySubject('Signed only message that was tempered during transit'); | ||
|
|
||
| await EmailScreen.checkEncryptionBadge('not encrypted'); | ||
| await EmailScreen.checkSignatureBadge('bad signature'); | ||
| await EmailScreen.clickBackButton(); | ||
| }); | ||
| }); | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one is not right - signed only message that is missing pubkey should have encryption badge of
not encryptedand a signature badge that says it cannot be verified due to missing pubkey.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe email was crafter with error. Let's create separate issue