This commit is contained in:
Eloy Lafuente (stronk7) 2019-09-18 23:15:13 +02:00
commit 0059a5e52e
2 changed files with 21 additions and 1 deletions

View File

@ -51,6 +51,7 @@ Feature: Upload users
And I navigate to "Users > Accounts > Upload users" in site administration
When I upload "lib/tests/fixtures/upload_users.csv" file to "File" filemanager
And I press "Upload users"
And I should see "Upload users preview"
And I set the following fields to these values:
| City/town | Brighton |
| Department | Purchasing |
@ -77,6 +78,7 @@ Feature: Upload users
When I navigate to "Users > Accounts > Upload users" in site administration
And I upload "lib/tests/fixtures/upload_users_profile.csv" file to "File" filemanager
And I press "Upload users"
And I should see "Upload users preview"
And I press "Upload users"
# Check that users were created and the superfield is filled.
And I navigate to "Users > Accounts > Browse list of users" in site administration
@ -85,6 +87,21 @@ Feature: Upload users
And I should see "The big guy"
And I log out
@javascript
Scenario: Upload users setting their email stop value
Given I log in as "admin"
And I navigate to "Users > Accounts > Upload users" in site administration
When I upload "lib/tests/fixtures/upload_users_emailstop.csv" file to "File" filemanager
And I press "Upload users"
Then I should see "Upload users preview"
And the following should exist in the "uupreview" table:
| CSV line | username | emailstop |
| 2 | jbloggs | 1 |
| 3 | fbloggs | 0 |
And I press "Upload users"
And I should see "Users created: 2"
And I log out
@javascript
Scenario: Upload users setting their user theme
Given the following "courses" exist:
@ -170,4 +187,4 @@ Feature: Upload users
Then I should see "2 January 2020" in the "Enrolment starts" "table_row"
And I should see "12 January 2020" in the "Enrolment ends" "table_row"
And I click on "Close" "button"
And I log out
And I log out

View File

@ -0,0 +1,3 @@
username,password,firstname,lastname,email,emailstop
jbloggs,hunter42,Joe,Bloggs,jbloggs@example.com,1
fbloggs,hunter42,Fred,Bloggs,fbloggs@example.com,0
1 username password firstname lastname email emailstop
2 jbloggs hunter42 Joe Bloggs jbloggs@example.com 1
3 fbloggs hunter42 Fred Bloggs fbloggs@example.com 0