mirror of
https://github.com/ProtonMail/proton-bridge.git
synced 2025-12-24 02:46:44 +00:00
GODT-1650: text/html sending tests
This commit is contained in:
@ -5,7 +5,7 @@ Feature: IMAP get mailbox info
|
||||
| name | type |
|
||||
| one | folder |
|
||||
And the address "user@pm.me" of account "user@pm.me" has the following messages in "one":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
And bridge starts
|
||||
|
||||
@ -6,7 +6,7 @@ Feature: IMAP copy messages
|
||||
| mbox | folder |
|
||||
| label | label |
|
||||
And the address "user@pm.me" of account "user@pm.me" has the following messages in "Inbox":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
| jane.doe@mail.com | name@pm.me | bar | true |
|
||||
And bridge starts
|
||||
@ -17,37 +17,37 @@ Feature: IMAP copy messages
|
||||
Scenario: Copy message to label
|
||||
When IMAP client "1" copies the message with subject "foo" from "INBOX" to "Labels/label"
|
||||
Then IMAP client "1" sees the following messages in "INBOX":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
| jane.doe@mail.com | name@pm.me | bar | true |
|
||||
And IMAP client "1" sees the following messages in "Labels/label":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
|
||||
Scenario: Copy all messages to label
|
||||
When IMAP client "1" copies all messages from "INBOX" to "Labels/label"
|
||||
Then IMAP client "1" sees the following messages in "INBOX":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
| jane.doe@mail.com | name@pm.me | bar | true |
|
||||
And IMAP client "1" sees the following messages in "Labels/label":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
| jane.doe@mail.com | name@pm.me | bar | true |
|
||||
|
||||
Scenario: Copy message to folder does move
|
||||
When IMAP client "1" copies the message with subject "foo" from "INBOX" to "Folders/mbox"
|
||||
Then IMAP client "1" eventually sees the following messages in "INBOX":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| jane.doe@mail.com | name@pm.me | bar | true |
|
||||
And IMAP client "1" sees the following messages in "Folders/mbox":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
|
||||
Scenario: Copy all messages to folder does move
|
||||
When IMAP client "1" copies all messages from "INBOX" to "Folders/mbox"
|
||||
Then IMAP client "1" sees the following messages in "Folders/mbox":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
| jane.doe@mail.com | name@pm.me | bar | true |
|
||||
And IMAP client "1" eventually sees 0 messages in "INBOX"
|
||||
@ -55,7 +55,7 @@ Feature: IMAP copy messages
|
||||
Scenario: Copy message from Inbox to Sent is not possible
|
||||
When IMAP client "1" copies the message with subject "foo" from "INBOX" to "Sent"
|
||||
Then IMAP client "1" eventually sees the following messages in "INBOX":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| john.doe@mail.com | user@pm.me | foo | false |
|
||||
| jane.doe@mail.com | name@pm.me | bar | true |
|
||||
And IMAP client "1" eventually sees 0 messages in "Sent"
|
||||
344
tests/features/smtp/send/html.feature
Normal file
344
tests/features/smtp/send/html.feature
Normal file
@ -0,0 +1,344 @@
|
||||
Feature: SMTP sending of plain messages
|
||||
Background:
|
||||
Given there exists an account with username "user@pm.me" and password "password"
|
||||
And there exists an account with username "bridgetest@protonmail.com" and password "password"
|
||||
And there exists an account with username "bridgetest2@protonmail.com" and password "password"
|
||||
And bridge starts
|
||||
And the user logs in with username "user@pm.me" and password "password"
|
||||
And user "user@pm.me" connects and authenticates SMTP client "1"
|
||||
|
||||
Scenario: HTML message to external account
|
||||
When SMTP client "1" sends the following message from "user@pm.me" to "pm.bridge.qa@gmail.com":
|
||||
"""
|
||||
From: Bridge Test <user@pm.me>
|
||||
To: External Bridge <pm.bridge.qa@gmail.com>
|
||||
Subject: HTML text external
|
||||
Content-Disposition: inline
|
||||
Content-Transfer-Encoding: quoted-printable
|
||||
Content-Type: text/html; charset=utf-8
|
||||
In-Reply-To: <base64hashOfSomeMessage@protonmail.internalid>
|
||||
|
||||
<html><body>This is body of <b>HTML mail</b> without attachment<body></html>
|
||||
|
||||
"""
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | HTML text external |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
"Message": {
|
||||
"Subject": "HTML text external",
|
||||
"Sender": {
|
||||
"Name": "Bridge Test"
|
||||
},
|
||||
"ToList": [
|
||||
{
|
||||
"Address": "pm.bridge.qa@gmail.com",
|
||||
"Name": "External Bridge"
|
||||
}
|
||||
],
|
||||
"CCList": [],
|
||||
"BCCList": [],
|
||||
"MIMEType": "text/html"
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
Scenario: HTML message with inline image to external account
|
||||
When SMTP client "1" sends the following message from "user@pm.me" to "pm.bridge.qa@gmail.com":
|
||||
"""
|
||||
From: Bridge Test <user@pm.me>
|
||||
To: External Bridge <pm.bridge.qa@gmail.com>
|
||||
Subject: Html Inline External
|
||||
Content-Disposition: inline
|
||||
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.0
|
||||
MIME-Version: 1.0
|
||||
Content-Language: en-US
|
||||
Content-Type: multipart/related; boundary="------------61FA22A41A3F46E8E90EF528"
|
||||
|
||||
This is a multi-part message in MIME format.
|
||||
--------------61FA22A41A3F46E8E90EF528
|
||||
Content-Type: text/html; charset=utf-8
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
</head>
|
||||
<body text="#000000" bgcolor="#FFFFFF">
|
||||
<p><br>
|
||||
</p>
|
||||
<p>Behold! An inline <img moz-do-not-send="false"
|
||||
src="cid:part1.D96BFAE9.E2E1CAE3@protonmail.com" alt=""
|
||||
width="24" height="24"><br>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
--------------61FA22A41A3F46E8E90EF528
|
||||
Content-Type: image/gif; name="email-action-left.gif"
|
||||
Content-Transfer-Encoding: base64
|
||||
Content-ID: <part1.D96BFAE9.E2E1CAE3@protonmail.com>
|
||||
Content-Disposition: inline; filename="email-action-left.gif"
|
||||
|
||||
R0lGODlhGAAYANUAACcsKOHs4kppTH6tgYWxiIq0jTVENpG5lDI/M7bRuEaJSkqOTk2RUU+P
|
||||
U16lYl+lY2iva262cXS6d3rDfYLNhWeeamKTZGSVZkNbRGqhbOPt4////+7u7qioqFZWVlNT
|
||||
UyIiIgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
|
||||
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAGAAYAAAG
|
||||
/8CNcLjRJAqVRqNSSGiI0GFgoKhar4NAdHioMhyRCYUyiTgY1cOWUH1ILgIDAGAQXCSPKgHa
|
||||
XUAyGCCCg4IYGRALCmpCAVUQFgiEkiAIFhBVWhtUDxmRk5IIGXkDRQoMEoGfHpIYEmhGCg4X
|
||||
nyAdHB+SFw4KRwoRArQdG7eEAhEKSAoTBoIdzs/Cw7iCBhMKSQoUAIJbQ8QgABQKStnbIN1C
|
||||
3+HjFcrMtdDO6dMg1dcFvsCfwt+CxsgJYs3a10+QLl4aTKGitYpQq1eaFHDyREtQqFGMHEGq
|
||||
SMkSJi4K/ACiZQiRIihsJL6JM6fOnTwK9kTpYgqMGDJm0JzsNuWKTw0FWdANMYJECRMnW4IA
|
||||
ADs=
|
||||
--------------61FA22A41A3F46E8E90EF528--
|
||||
|
||||
"""
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Html Inline External |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
"Message": {
|
||||
"Subject": "Html Inline External",
|
||||
"Sender": {
|
||||
"Name": "Bridge Test"
|
||||
},
|
||||
"ToList": [
|
||||
{
|
||||
"Address": "pm.bridge.qa@gmail.com",
|
||||
"Name": "External Bridge"
|
||||
}
|
||||
],
|
||||
"CCList": [],
|
||||
"BCCList": [],
|
||||
"MIMEType": "text/html"
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
Scenario: HTML message with alternative inline to internal account
|
||||
When SMTP client "1" sends the following message from "user@pm.me" to "bridgetest@protonmail.com":
|
||||
"""
|
||||
From: Bridge Test <user@pm.me>
|
||||
To: Internal Bridge <bridgetest@protonmail.com>
|
||||
Subject: Html Inline Alternative Internal
|
||||
Content-Disposition: inline
|
||||
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.0
|
||||
MIME-Version: 1.0
|
||||
Content-Type: multipart/alternative; boundary="------------5A259F4DE164B5ADA313F644"
|
||||
Content-Language: en-US
|
||||
|
||||
This is a multi-part message in MIME format.
|
||||
--------------5A259F4DE164B5ADA313F644
|
||||
Content-Type: text/plain; charset=utf-8
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
|
||||
Behold! An inline
|
||||
|
||||
|
||||
--------------5A259F4DE164B5ADA313F644
|
||||
Content-Type: multipart/related; boundary="------------61FA22A41A3F46E8E90EF528"
|
||||
|
||||
|
||||
--------------61FA22A41A3F46E8E90EF528
|
||||
Content-Type: text/html; charset=utf-8
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
</head>
|
||||
<body text="#000000" bgcolor="#FFFFFF">
|
||||
<p><br>
|
||||
</p>
|
||||
<p>Behold! An inline <img moz-do-not-send="false"
|
||||
src="cid:part1.D96BFAE9.E2E1CAE3@protonmail.com" alt=""
|
||||
width="24" height="24"><br>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
--------------61FA22A41A3F46E8E90EF528
|
||||
Content-Type: image/gif; name="email-action-left.gif"
|
||||
Content-Transfer-Encoding: base64
|
||||
Content-ID: <part1.D96BFAE9.E2E1CAE3@protonmail.com>
|
||||
Content-Disposition: inline; filename="email-action-left.gif"
|
||||
|
||||
R0lGODlhGAAYANUAACcsKOHs4kppTH6tgYWxiIq0jTVENpG5lDI/M7bRuEaJSkqOTk2RUU+P
|
||||
U16lYl+lY2iva262cXS6d3rDfYLNhWeeamKTZGSVZkNbRGqhbOPt4////+7u7qioqFZWVlNT
|
||||
UyIiIgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
|
||||
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAGAAYAAAG
|
||||
/8CNcLjRJAqVRqNSSGiI0GFgoKhar4NAdHioMhyRCYUyiTgY1cOWUH1ILgIDAGAQXCSPKgHa
|
||||
XUAyGCCCg4IYGRALCmpCAVUQFgiEkiAIFhBVWhtUDxmRk5IIGXkDRQoMEoGfHpIYEmhGCg4X
|
||||
nyAdHB+SFw4KRwoRArQdG7eEAhEKSAoTBoIdzs/Cw7iCBhMKSQoUAIJbQ8QgABQKStnbIN1C
|
||||
3+HjFcrMtdDO6dMg1dcFvsCfwt+CxsgJYs3a10+QLl4aTKGitYpQq1eaFHDyREtQqFGMHEGq
|
||||
SMkSJi4K/ACiZQiRIihsJL6JM6fOnTwK9kTpYgqMGDJm0JzsNuWKTw0FWdANMYJECRMnW4IA
|
||||
ADs=
|
||||
--------------61FA22A41A3F46E8E90EF528--
|
||||
|
||||
--------------5A259F4DE164B5ADA313F644--
|
||||
|
||||
"""
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| from | to | subject |
|
||||
| user@pm.me | bridgetest@protonmail.com | Html Inline Alternative Internal |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
"Message": {
|
||||
"Subject": "Html Inline Alternative Internal",
|
||||
"Sender": {
|
||||
"Name": "Bridge Test"
|
||||
},
|
||||
"ToList": [
|
||||
{
|
||||
"Address": "bridgetest@protonmail.com",
|
||||
"Name": "Internal Bridge"
|
||||
}
|
||||
],
|
||||
"CCList": [],
|
||||
"BCCList": [],
|
||||
"MIMEType": "text/html"
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
Scenario: HTML message with alternative inline to external account
|
||||
When SMTP client "1" sends the following message from "user@pm.me" to "pm.bridge.qa@gmail.com":
|
||||
"""
|
||||
From: Bridge Test <user@pm.me>
|
||||
To: External Bridge <pm.bridge.qa@gmail.com>
|
||||
Subject: Html Inline Alternative External
|
||||
Content-Disposition: inline
|
||||
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.0
|
||||
MIME-Version: 1.0
|
||||
Content-Type: multipart/alternative; boundary="------------5A259F4DE164B5ADA313F644"
|
||||
Content-Language: en-US
|
||||
|
||||
This is a multi-part message in MIME format.
|
||||
--------------5A259F4DE164B5ADA313F644
|
||||
Content-Type: text/plain; charset=utf-8
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
|
||||
Behold! An inline
|
||||
|
||||
|
||||
--------------5A259F4DE164B5ADA313F644
|
||||
Content-Type: multipart/related; boundary="------------61FA22A41A3F46E8E90EF528"
|
||||
|
||||
|
||||
--------------61FA22A41A3F46E8E90EF528
|
||||
Content-Type: text/html; charset=utf-8
|
||||
Content-Transfer-Encoding: 7bit
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
</head>
|
||||
<body text="#000000" bgcolor="#FFFFFF">
|
||||
<p><br>
|
||||
</p>
|
||||
<p>Behold! An inline <img moz-do-not-send="false"
|
||||
src="cid:part1.D96BFAE9.E2E1CAE3@protonmail.com" alt=""
|
||||
width="24" height="24"><br>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
--------------61FA22A41A3F46E8E90EF528
|
||||
Content-Type: image/gif; name="email-action-left.gif"
|
||||
Content-Transfer-Encoding: base64
|
||||
Content-ID: <part1.D96BFAE9.E2E1CAE3@protonmail.com>
|
||||
Content-Disposition: inline; filename="email-action-left.gif"
|
||||
|
||||
R0lGODlhGAAYANUAACcsKOHs4kppTH6tgYWxiIq0jTVENpG5lDI/M7bRuEaJSkqOTk2RUU+P
|
||||
U16lYl+lY2iva262cXS6d3rDfYLNhWeeamKTZGSVZkNbRGqhbOPt4////+7u7qioqFZWVlNT
|
||||
UyIiIgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
|
||||
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAGAAYAAAG
|
||||
/8CNcLjRJAqVRqNSSGiI0GFgoKhar4NAdHioMhyRCYUyiTgY1cOWUH1ILgIDAGAQXCSPKgHa
|
||||
XUAyGCCCg4IYGRALCmpCAVUQFgiEkiAIFhBVWhtUDxmRk5IIGXkDRQoMEoGfHpIYEmhGCg4X
|
||||
nyAdHB+SFw4KRwoRArQdG7eEAhEKSAoTBoIdzs/Cw7iCBhMKSQoUAIJbQ8QgABQKStnbIN1C
|
||||
3+HjFcrMtdDO6dMg1dcFvsCfwt+CxsgJYs3a10+QLl4aTKGitYpQq1eaFHDyREtQqFGMHEGq
|
||||
SMkSJi4K/ACiZQiRIihsJL6JM6fOnTwK9kTpYgqMGDJm0JzsNuWKTw0FWdANMYJECRMnW4IA
|
||||
ADs=
|
||||
--------------61FA22A41A3F46E8E90EF528--
|
||||
|
||||
--------------5A259F4DE164B5ADA313F644--
|
||||
|
||||
"""
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Html Inline Alternative External |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
"Message": {
|
||||
"Subject": "Html Inline Alternative External",
|
||||
"Sender": {
|
||||
"Name": "Bridge Test"
|
||||
},
|
||||
"ToList": [
|
||||
{
|
||||
"Address": "pm.bridge.qa@gmail.com",
|
||||
"Name": "External Bridge"
|
||||
}
|
||||
],
|
||||
"CCList": [],
|
||||
"BCCList": [],
|
||||
"MIMEType": "text/html"
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
Scenario: HTML message with extremely long line (greater than default 2000 line limit) to external account
|
||||
When SMTP client "1" sends the following message from "user@pm.me" to "pm.bridge.qa@gmail.com":
|
||||
"""
|
||||
From: Bridge Test <user@pm.me>
|
||||
To: External Bridge <pm.bridge.qa@gmail.com>
|
||||
Subject: HTML text external
|
||||
Content-Disposition: inline
|
||||
Content-Transfer-Encoding: quoted-printable
|
||||
Content-Type: text/html; charset=utf-8
|
||||
In-Reply-To: <base64hashOfSomeMessage@protonmail.internalid>
|
||||
|
||||
<html><body>aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa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IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | HTML text external |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
"Message": {
|
||||
"Subject": "HTML text external",
|
||||
"Sender": {
|
||||
"Name": "Bridge Test"
|
||||
},
|
||||
"ToList": [
|
||||
{
|
||||
"Address": "pm.bridge.qa@gmail.com",
|
||||
"Name": "External Bridge"
|
||||
}
|
||||
],
|
||||
"CCList": [],
|
||||
"BCCList": [],
|
||||
"MIMEType": "text/html"
|
||||
}
|
||||
}
|
||||
"""
|
||||
@ -19,8 +19,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | subject | unread |
|
||||
| user@pm.me | bridgetest@protonmail.com | | false |
|
||||
| from | to | subject |
|
||||
| user@pm.me | bridgetest@protonmail.com | |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
@ -54,8 +54,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | subject | unread |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | | false |
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
@ -92,8 +92,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | subject | unread |
|
||||
| user@pm.me | bridgetest@protonmail.com | Plain text internal | false |
|
||||
| from | to | subject |
|
||||
| user@pm.me | bridgetest@protonmail.com | Plain text internal |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
@ -130,8 +130,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | subject | unread |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain text external | false |
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain text external |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
@ -168,8 +168,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | subject | unread |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain text no charset external | false |
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain text no charset external |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
@ -209,8 +209,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | subject | unread |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain text no charset external | false |
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain text no charset external |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
@ -245,8 +245,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | subject | unread |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain, no charset, no content, external | false |
|
||||
| from | to | subject |
|
||||
| user@pm.me | pm.bridge.qa@gmail.com | Plain, no charset, no content, external |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
@ -285,8 +285,8 @@ Feature: SMTP sending of plain messages
|
||||
Then it succeeds
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1"
|
||||
Then IMAP client "1" eventually sees the following messages in "Sent":
|
||||
| sender | recipient | cc | subject | unread |
|
||||
| user@pm.me | bridgetest@protonmail.com | bridgetest2@protonmail.com | RCPT-CC test | false |
|
||||
| from | to | cc | subject |
|
||||
| user@pm.me | bridgetest@protonmail.com | bridgetest2@protonmail.com | RCPT-CC test |
|
||||
And the body in the "POST" request to "/mail/v4/messages" is:
|
||||
"""
|
||||
{
|
||||
|
||||
@ -7,11 +7,11 @@ Feature: Address mode
|
||||
| one | folder |
|
||||
| two | folder |
|
||||
And the address "user@pm.me" of account "user@pm.me" has the following messages in "one":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
And the address "alias@pm.me" of account "user@pm.me" has the following messages in "two":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
And bridge starts
|
||||
@ -21,30 +21,30 @@ Feature: Address mode
|
||||
Scenario: The user is in combined mode
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1" with address "user@pm.me"
|
||||
Then IMAP client "1" sees the following messages in "Folders/one":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
And IMAP client "1" sees the following messages in "Folders/two":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
And IMAP client "1" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
When user "user@pm.me" connects and authenticates IMAP client "2" with address "alias@pm.me"
|
||||
Then IMAP client "2" sees the following messages in "Folders/one":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
And IMAP client "2" sees the following messages in "Folders/two":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
And IMAP client "2" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
@ -55,22 +55,22 @@ Feature: Address mode
|
||||
And user "user@pm.me" finishes syncing
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1" with address "user@pm.me"
|
||||
Then IMAP client "1" sees the following messages in "Folders/one":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
And IMAP client "1" sees 0 messages in "Folders/two"
|
||||
And IMAP client "1" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
When user "user@pm.me" connects and authenticates IMAP client "2" with address "alias@pm.me"
|
||||
Then IMAP client "2" sees 0 messages in "Folders/one"
|
||||
And IMAP client "2" sees the following messages in "Folders/two":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
And IMAP client "2" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
|
||||
@ -81,14 +81,14 @@ Feature: Address mode
|
||||
And user "user@pm.me" finishes syncing
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1" with address "user@pm.me"
|
||||
Then IMAP client "1" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
When user "user@pm.me" connects and authenticates IMAP client "2" with address "alias@pm.me"
|
||||
Then IMAP client "2" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
@ -97,14 +97,14 @@ Feature: Address mode
|
||||
Scenario: The user adds an address while in combined mode
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1" with address "user@pm.me"
|
||||
Then IMAP client "1" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
When user "user@pm.me" connects and authenticates IMAP client "2" with address "alias@pm.me"
|
||||
Then IMAP client "2" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
@ -113,7 +113,7 @@ Feature: Address mode
|
||||
And bridge sends an address created event for user "user@pm.me"
|
||||
When user "user@pm.me" connects and authenticates IMAP client "3" with address "other@pm.me"
|
||||
Then IMAP client "3" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
@ -124,12 +124,12 @@ Feature: Address mode
|
||||
And user "user@pm.me" finishes syncing
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1" with address "user@pm.me"
|
||||
And IMAP client "1" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
When user "user@pm.me" connects and authenticates IMAP client "2" with address "alias@pm.me"
|
||||
And IMAP client "2" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
Given the account "user@pm.me" has additional address "other@pm.me"
|
||||
@ -140,14 +140,14 @@ Feature: Address mode
|
||||
Scenario: The user deletes an address while in combined mode
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1" with address "user@pm.me"
|
||||
Then IMAP client "1" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
When user "user@pm.me" connects and authenticates IMAP client "2" with address "alias@pm.me"
|
||||
Then IMAP client "2" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
@ -162,12 +162,12 @@ Feature: Address mode
|
||||
And user "user@pm.me" finishes syncing
|
||||
When user "user@pm.me" connects and authenticates IMAP client "1" with address "user@pm.me"
|
||||
And IMAP client "1" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
When user "user@pm.me" connects and authenticates IMAP client "2" with address "alias@pm.me"
|
||||
And IMAP client "2" sees the following messages in "All Mail":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| c@pm.me | c@pm.me | three | true |
|
||||
| d@pm.me | d@pm.me | four | false |
|
||||
Given the account "user@pm.me" no longer has additional address "alias@pm.me"
|
||||
|
||||
@ -7,11 +7,11 @@ Feature: Bridge can fully sync an account
|
||||
| two | folder |
|
||||
| three | label |
|
||||
And the address "user@pm.me" of account "user@pm.me" has the following messages in "one":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
And the address "user@pm.me" of account "user@pm.me" has the following messages in "two":
|
||||
| sender | recipient | subject | unread |
|
||||
| from | to | subject | unread |
|
||||
| a@pm.me | a@pm.me | one | true |
|
||||
| b@pm.me | b@pm.me | two | false |
|
||||
And bridge starts
|
||||
|
||||
Reference in New Issue
Block a user