mirror of
https://github.com/ProtonMail/proton-bridge.git
synced 2025-12-17 15:46:44 +00:00
Use label.Path instead of Name
This commit is contained in:
@ -1,11 +1,11 @@
|
||||
Feature: IMAP list mailboxes
|
||||
Background:
|
||||
Given there is connected user "user"
|
||||
And there is "user" with mailbox "Folders/mbox1"
|
||||
And there is "user" with mailbox "Labels/mbox2"
|
||||
And there is IMAP client logged in as "user"
|
||||
|
||||
Scenario: List mailboxes
|
||||
Given there is "user" with mailbox "Folders/mbox1"
|
||||
And there is "user" with mailbox "Labels/mbox2"
|
||||
And there is IMAP client logged in as "user"
|
||||
When IMAP client lists mailboxes
|
||||
Then IMAP response contains "INBOX"
|
||||
Then IMAP response contains "Sent"
|
||||
@ -14,3 +14,16 @@ Feature: IMAP list mailboxes
|
||||
Then IMAP response contains "All Mail"
|
||||
Then IMAP response contains "Folders/mbox1"
|
||||
Then IMAP response contains "Labels/mbox2"
|
||||
|
||||
@ignore-live
|
||||
Scenario: List mailboxes with subfolders
|
||||
# Escaped slash in the name contains slash in the name.
|
||||
# Not-escaped slash in the name means tree structure.
|
||||
# We keep escaping in an IMAP communication so each mailbox is unique and
|
||||
# both mailboxes are accessible. The slash is visible in the IMAP client.
|
||||
Given there is "user" with mailbox "Folders/a\/b"
|
||||
And there is "user" with mailbox "Folders/a/b"
|
||||
And there is IMAP client logged in as "user"
|
||||
When IMAP client lists mailboxes
|
||||
Then IMAP response contains "Folders/a\/b"
|
||||
Then IMAP response contains "Folders/a/b"
|
||||
|
||||
51
test/features/bridge/imap/message/delete_from_trash.feature
Normal file
51
test/features/bridge/imap/message/delete_from_trash.feature
Normal file
@ -0,0 +1,51 @@
|
||||
Feature: IMAP remove messages from Trash
|
||||
Background:
|
||||
Given there is connected user "user"
|
||||
And there is "user" with mailbox "Folders/mbox"
|
||||
And there is "user" with mailbox "Labels/label"
|
||||
|
||||
Scenario Outline: Message in Trash/Spam and some other label is not permanently deleted
|
||||
Given there are messages in mailbox "<mailbox>" for "user"
|
||||
| from | to | subject | body |
|
||||
| john.doe@mail.com | user@pm.me | foo | hello |
|
||||
| jane.doe@mail.com | name@pm.me | bar | world |
|
||||
And there is IMAP client logged in as "user"
|
||||
And there is IMAP client selected in "<mailbox>"
|
||||
When IMAP client copies messages "2" to "Labels/label"
|
||||
Then IMAP response is "OK"
|
||||
When IMAP client marks message "2" as deleted
|
||||
Then IMAP response is "OK"
|
||||
And mailbox "<mailbox>" for "user" has 2 messages
|
||||
And mailbox "All Mail" for "user" has 2 messages
|
||||
And mailbox "Labels/label" for "user" has 1 messages
|
||||
When IMAP client sends expunge
|
||||
Then IMAP response is "OK"
|
||||
And mailbox "<mailbox>" for "user" has 1 messages
|
||||
And mailbox "All Mail" for "user" has 2 messages
|
||||
And mailbox "Labels/label" for "user" has 1 messages
|
||||
|
||||
Examples:
|
||||
| mailbox |
|
||||
| Spam |
|
||||
| Trash |
|
||||
|
||||
Scenario Outline: Message in Trash/Spam only is permanently deleted
|
||||
Given there are messages in mailbox "<mailbox>" for "user"
|
||||
| from | to | subject | body |
|
||||
| john.doe@mail.com | user@pm.me | foo | hello |
|
||||
| jane.doe@mail.com | name@pm.me | bar | world |
|
||||
And there is IMAP client logged in as "user"
|
||||
And there is IMAP client selected in "<mailbox>"
|
||||
When IMAP client marks message "2" as deleted
|
||||
Then IMAP response is "OK"
|
||||
And mailbox "<mailbox>" for "user" has 2 messages
|
||||
And mailbox "All Mail" for "user" has 2 messages
|
||||
When IMAP client sends expunge
|
||||
Then IMAP response is "OK"
|
||||
And mailbox "<mailbox>" for "user" has 1 messages
|
||||
And mailbox "All Mail" for "user" has 1 messages
|
||||
|
||||
Examples:
|
||||
| mailbox |
|
||||
| Spam |
|
||||
| Trash |
|
||||
@ -0,0 +1,60 @@
|
||||
Feature: IMAP move messages by append and delete (without MOVE support, e.g., Outlook)
|
||||
Background:
|
||||
Given there is connected user "user"
|
||||
And there is "user" with mailbox "Folders/mbox"
|
||||
And there is IMAP client "source" logged in as "user"
|
||||
And there is IMAP client "target" logged in as "user"
|
||||
|
||||
Scenario Outline: Move message from INBOX to mailbox by append and delete
|
||||
# Messages are inserted in opposite way to keep increasing ID.
|
||||
# Sequence numbers are then opposite than listed below.
|
||||
Given there are messages in mailbox "INBOX" for "user"
|
||||
| from | to | subject | body |
|
||||
| john.doe@mail.com | user@pm.me | foo | hello |
|
||||
| jane.doe@mail.com | name@pm.me | bar | world |
|
||||
And there is IMAP client "source" selected in "INBOX"
|
||||
And there is IMAP client "target" selected in "<mailbox>"
|
||||
When IMAP clients "source" and "target" move message "1" of "user" from "INBOX" to "<mailbox>" by append and delete
|
||||
Then IMAP response to "source" is "OK"
|
||||
Then IMAP response to "target" is "OK"
|
||||
When IMAP client "source" sends expunge
|
||||
Then IMAP response to "source" is "OK"
|
||||
And mailbox "INBOX" for "user" has messages
|
||||
| from | to | subject |
|
||||
| john.doe@mail.com | user@pm.me | foo |
|
||||
And mailbox "<mailbox>" for "user" has messages
|
||||
| from | to | subject |
|
||||
| jane.doe@mail.com | name@pm.me | bar |
|
||||
|
||||
Examples:
|
||||
| mailbox |
|
||||
| Archive |
|
||||
| Folders/mbox |
|
||||
| Spam |
|
||||
| Trash |
|
||||
|
||||
Scenario Outline: Move message from Trash/Spam to INBOX by append and delete
|
||||
# Messages are inserted in opposite way to keep increasing ID.
|
||||
# Sequence numbers are then opposite than listed below.
|
||||
Given there are messages in mailbox "<mailbox>" for "user"
|
||||
| from | to | subject | body |
|
||||
| john.doe@mail.com | user@pm.me | foo | hello |
|
||||
| jane.doe@mail.com | name@pm.me | bar | world |
|
||||
And there is IMAP client "source" selected in "<mailbox>"
|
||||
And there is IMAP client "target" selected in "INBOX"
|
||||
When IMAP clients "source" and "target" move message "1" of "user" from "<mailbox>" to "INBOX" by append and delete
|
||||
Then IMAP response to "source" is "OK"
|
||||
Then IMAP response to "target" is "OK"
|
||||
When IMAP client "source" sends expunge
|
||||
Then IMAP response to "source" is "OK"
|
||||
And mailbox "INBOX" for "user" has messages
|
||||
| from | to | subject |
|
||||
| jane.doe@mail.com | name@pm.me | bar |
|
||||
And mailbox "<mailbox>" for "user" has messages
|
||||
| from | to | subject |
|
||||
| john.doe@mail.com | user@pm.me | foo |
|
||||
|
||||
Examples:
|
||||
| mailbox |
|
||||
| Spam |
|
||||
| Trash |
|
||||
Reference in New Issue
Block a user