/
user_confirmation.feature
57 lines (49 loc) · 3.09 KB
/
user_confirmation.feature
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
Feature: Thankyous to unregistered users trigger
As an unregistered user who thanks or is thanked by another
In order to use Merciboq
I want to confirm my account
Background: Clear out the email queue
Given no emails have been sent
Scenario: Unregistered THANKER signs up after sending a thankyou
Given a thankyou email is sent from one unregistered user to another
Then the thanker should have a confirmation email
When the thanker opens her email
Then she should see confirmation instructions in the subject
And she should see "confirm" in the email body
When she follows the confirmation in the email body
Then she should see "Confirm your account" in the title
And when she fills in her password and confirmation
And she presses "Choose my password"
Then she should see "Your account was successfully confirmed"
Scenario: Unregistered WELCOMER signs up after receiving a thankyou
Given a thankyou email is sent from one unregistered user to another
Then the welcomer should have a confirmation email
When the welcomer opens her email
Then she should see confirmation instructions in the subject
And she should see "confirm" in the email body
When she follows the confirmation in the email body
Then she should see "Confirm your account" in the title
And when she fills in her password and confirmation
And she presses "Choose my password"
Then she should see "Your account was successfully confirmed"
Scenario: Unregistered WELCOMER signs up after a thankyou
Given a thankyou email is sent from one unregistered user to another
Then the welcomer should have a confirmation email
When the welcomer opens her email
Then she should see confirmation instructions in the subject
Scenario: Registered THANKER does not receive confirmation after thankyou
Given a confirmed user "Custardy Customer" with an email "customer@test.com" and password "password"
And no emails have been sent
And a thankyou email from "customer@test.com" to an unregistered user
Then "customer@test.com" should not receive an email with subject "Welcome to Merciboq! -- Please confirm your account for us."
Scenario: Registered WELCOMER does not receive confirmation after thankyou
Given a confirmed user "Harry Hairstylist" with an email "hairstylist@test.com" and password "password"
And no emails have been sent
And a thankyou email from "customer@test.com" to "hairstylist@test.com"
Then "hairstylist@test.com" should not receive an email with subject "Welcome to Merciboq! -- Please confirm your account for us."
Scenario: Registered THANKER thanks registered WELCOMER
Given a confirmed user "Harry Hairstylist" with an email "hairstylist@test.com" and password "password"
And a confirmed user "Custardy Customer" with an email "customer@test.com" and password "password"
And no emails have been sent
And a thankyou email from "customer@test.com" to "hairstylist@test.com"
Then "hairstylist@test.com" should not receive an email with subject "Welcome to Merciboq! -- Please confirm your account for us."