Commit 1c17158a authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review
Browse files

Merge "Behat Testsuite: Tidying up messages files (Bug #1446395)"

parents 1db65c3f e192884f
@javascript @core @core_administration
@javascript @core @core_messages @core_administration
Feature: Admins are allowed to see more types of messages than a user
In order to see what types are visible to me
As an admin/student
......
@javascript @core core_mesages
@javascript @core core_messages
Feature: Send messages to other users
In order to send a message to another user
As an admin I need to create an user
So I can send it messages
Background:
Given the following "users" exist:
| username | password | email | firstname | lastname | institution | authname | role |
| Bob | Password1 | test01@example.com | Bob | Mc Bobby | mahara | internal | member |
Scenario: Sending messages between user and admin (Bug 1426983)
# Log in as "Admin" user
Given I log in as "admin" with password "Password1"
# Verifying log in was successful
And I should see "Admin User"
# Creating user 1
And I follow "Administration"
And I choose "Add user" in "Users"
And I fill in the following:
| firstname | Bob |
| lastname | bobby |
| email | bob@example.com |
| username | bob |
| password | mahara1 |
And I press "Create user"
When I follow "Return to site"
# Log in as "Admin" user
Given I log in as "admin" with password "Password1"
# Verifying log in was successful
And I should see "Admin User"
# Sending message 1
And I choose "Find friends" in "Groups"
And I follow "Bob"
......@@ -48,16 +42,10 @@ Scenario: Sending messages between user and admin (Bug 1426983)
# Log out as "Admin" user
And I follow "Logout"
# Log in as user 1
Then I log in as "bob" with password "mahara1"
And I fill in the following:
| New password | mahara2 |
| Confirm password | mahara2 |
And I press "Submit"
# Verifying password was changed successfully
And I should see "Your new password has been saved"
# Confirming all messages has been received
And I follow "Inbox"
And I should see "Hi there"
And I should see "Hi there2"
And I should see "Hi there3"
And I should not see "Call stack"
Then I log in as "Bob" with password "Password1"
# Confirming all messages has been received
And I follow "Inbox"
And I should see "Hi there"
And I should see "Hi there2"
And I should see "Hi there3"
And I should not see "Call stack"
......@@ -9,9 +9,11 @@
Given the following "users" exist:
| username | password | email | firstname | lastname | institution | authname | role |
| userA | Password1 | test01@example.com | Pete | Mc | mahara | internal | member |
And I follow "Administration"
When I follow "Administration"
And I follow "Users"
And I follow "Pete"
And I follow "Send message"
And I should see "*"
Then I should see "Recipients *"
And I should see "Subject *"
And I should see "Message *"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment