Logo: Relish

  1. Sign in

Project: Caren

Posting messages

In order to communicate
The user
wants to be able post messages

Background
Given
an account "Andre" with email "[email protected]"
And
an account "Ria" with email "[email protected]"
And
an account "Oscar" with email "[email protected]"
And
"Andre" has a sharing relationship with "Ria"
And
"Andre" receives care
And
"Ria" is logged in
Scenarios
Post a message to someone's page
Given
I am on Andre's page
When
I fill in "personal_message_body" with "Testing 1,2,3"
And
I press "Post"
Then
I should see "Testing 1,2,3" within "#messages"
And
"[email protected]" should receive no email
And
"[email protected]" should receive an email
When
I open the email
Then
I should see /message/ in the email subject
And
I should see /Testing 1,2,3/ in the email body
Trying to post a message to someone's page using an email (not in network)
When
"Oscar" sends an email to Andre's page with "Testing 1,2,3"
Then
"[email protected]" should receive an email
When
I open the email
Then
I should see /I am sorry/ in the email body
Trying to post a message to someone's page using an email (unknown email)
When
"[email protected]" sends an email to Andre's page with "Testing 1,2,3"
Then
"[email protected]" should receive an email
When
I open the email
Then
I should see /I am sorry/ in the email body
Post a message to someone's page using an email
When
"Ria" sends an email to Andre's page with "Testing 1,2,3"
Given
I am on Andre's page
Then
I should see "Testing 1,2,3" within "#messages"
And
"[email protected]" should receive an email
When
I open the email
Then
I should see /message/ in the email subject
And
I should see /Testing 1,2,3/ in the email body
Post a message to someone's page using an email with signature
When
"Ria" sends an email to Andre's page with:
Testing 5,6,7

Regards,
Ria
Given
I am on Andre's page
Then
I should not see "Regards" within "#messages"
Posting a reply to someone's message
Given
I am on Andre's page
When
I fill in "personal_message[body]" with "Testing 1,2,3"
And
I press "Post"
Then
I should see "Testing 1,2,3" within "#messages"
When
I follow "Logout"
Given
"Andre" is logged in
And
I am on Andre's page
When
I follow "Reply"
And
I fill in "personal_message[body]" with "Testing 5,6,7" within "#messages"
And
I press "Post" within "#messages"
Then
I should see "Testing 5,6,7" within "#messages"
Posting a reply to someone's message using email
Given
I am on Andre's page
When
I fill in "personal_message[body]" with "Testing 1,2,3"
And
I press "Post"
Then
I should see "Testing 1,2,3" within "#messages"
And
"[email protected]" should receive an email
When
I open the email
And
"Andre" replies to the email with "Testing 5,6,7"
Given
I am on Andre's page
Then
I should see "Testing 5,6,7" within "#messages"
And
"[email protected]" should receive an email
Removing a message
Given
I am on Andre's page
When
I fill in "personal_message_body" with "Testing 1,2,3"
And
I press "Post"
When
I follow "Delete this message" within "#messages"
And
I confirm the javascript popup
Then
I should not see "Testing 1,2,3" within "#messages"

Last published over 5 years ago by Dreetje.