forked from moodle/moodle
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MDL-46891 behat: Optimised login step and context helper
- Loading branch information
Rajesh Taneja
committed
Mar 11, 2016
1 parent
42ad096
commit 86055d1
Showing
6 changed files
with
79 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
@auth @auth_manual | ||
Feature: Test manual authentication works. | ||
In order to check manual authentication | ||
As a teacher | ||
I need to go on login page and enter username and password. | ||
|
||
Background: | ||
Given the following "users" exist: | ||
| username | | ||
| teacher1 | | ||
|
||
@javascript | ||
Scenario: Check login works with javascript. | ||
Given I am on homepage | ||
And I expand navigation bar | ||
And I click on "Log in" "link" in the ".logininfo" "css_element" | ||
When I set the field "Username" to "teacher1" | ||
And I set the field "Password" to "teacher1" | ||
When I press "Log in" | ||
Then I should see "You are logged in as" | ||
|
||
Scenario: Check login works without javascript. | ||
Given I am on homepage | ||
And I click on "Log in" "link" in the ".logininfo" "css_element" | ||
When I set the field "Username" to "teacher1" | ||
And I set the field "Password" to "teacher1" | ||
When I press "Log in" | ||
Then I should see "You are logged in as" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters