1 |
efrain |
1 |
@core @core_user @_file_upload @javascript
|
|
|
2 |
Feature: The private files page allows users to store files privately in moodle.
|
|
|
3 |
In order to store a private file in moodle
|
|
|
4 |
As an authenticated user
|
|
|
5 |
I can upload the file to my private files area from the private files page
|
|
|
6 |
|
|
|
7 |
Background:
|
|
|
8 |
Given the following "users" exist:
|
|
|
9 |
| username | firstname | lastname | email |
|
|
|
10 |
| user1 | User | 1 | user1@example.com |
|
|
|
11 |
|
|
|
12 |
Scenario: Upload a file to the private files area from the private files page
|
|
|
13 |
Given I log in as "user1"
|
|
|
14 |
And I follow "Private files" in the user menu
|
|
|
15 |
And I should see "User 1" in the ".page-context-header" "css_element"
|
|
|
16 |
And I should see "Private files" in the "region-main" "region"
|
|
|
17 |
And I upload "lib/tests/fixtures/empty.txt" file to "Files" filemanager
|
|
|
18 |
When I press "Save changes"
|
|
|
19 |
Then I should see "1" elements in "Files" filemanager
|
|
|
20 |
And I should see "empty.txt" in the ".fp-content .fp-file" "css_element"
|