1 |
efrain |
1 |
@local @local_downloadcenter @_file_upload
|
|
|
2 |
Feature: Within a moodle instance a student should be able to see folders in Download Center.
|
|
|
3 |
|
|
|
4 |
Background:
|
|
|
5 |
Given the following "users" exist:
|
|
|
6 |
| username | firstname | lastname | email |
|
|
|
7 |
| teacher1 | Tina | Teacher1 | teacher1@example.com |
|
|
|
8 |
| student1 | Sam1 | Student1 | student1@example.com |
|
|
|
9 |
And the following "courses" exist:
|
|
|
10 |
| fullname | shortname | category |
|
|
|
11 |
| Course 1 | C1 | 0 |
|
|
|
12 |
And the following "course enrolments" exist:
|
|
|
13 |
| user | course | role |
|
|
|
14 |
| teacher1 | C1 | editingteacher |
|
|
|
15 |
| student1 | C1 | student |
|
|
|
16 |
@javascript
|
|
|
17 |
Scenario: Check Folder in Download Center
|
|
|
18 |
Given I log in as "admin"
|
|
|
19 |
And I am on "Course 1" course homepage with editing mode on
|
|
|
20 |
And I add a "Folder" to section "2" and I fill the form with:
|
|
|
21 |
| Name | Test Folder |
|
|
|
22 |
| Description | Test Folder|
|
|
|
23 |
And I follow "Test Folder"
|
|
|
24 |
And I press "Edit"
|
|
|
25 |
And I upload "lib/tests/fixtures/gd-logo.png" file to "Files" filemanager
|
|
|
26 |
And I follow "Download center"
|
|
|
27 |
Then I should see "Test Folder"
|
|
|
28 |
And I log out
|
|
|
29 |
And I log in as "student1"
|
|
|
30 |
And I am on "Course 1" course homepage
|
|
|
31 |
And I follow "Download center"
|
|
|
32 |
Then I should see "Test Folder"
|