| Server IP : 172.67.187.206 / Your IP : 172.71.28.155 Web Server : Apache/2.4.25 (Win32) OpenSSL/1.0.2j PHP/5.6.30 System : Windows NT WIN-ECQAAA40806 6.2 build 9200 (Windows Server 2012 Standard Edition) i586 User : SYSTEM ( 0) PHP Version : 5.6.30 Disable Function : NONE MySQL : ON | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : E:/Inetpub/www/myschool/triamudom/tuprblearn/calendar/tests/behat/ |
Upload File : |
@core @core_calendar @core_calendar_export
Feature: Export calendar events
In order to be able to use my calendar events outside of Moodle
As a user
I need to export calendar events in iCalendar format
Background:
Given the following "users" exist:
| username | firstname | lastname | email |
| student1 | Student | 1 | [email protected] |
And the following "courses" exist:
| fullname | shortname | format |
| Course 1 | C1 | topics |
And the following "course enrolments" exist:
| user | course | role |
| student1 | C1 | student |
And I log in as "student1"
Scenario: Viewing calendar export options
Given I follow "This month"
When I click on "Export calendar" "button"
Then I should see "All events"
And I should see "Events related to courses"
And I should see "Events related to groups"
And I should see "My personal events"
Scenario: Generating calendar URL for all events
Given I follow "This month"
And I click on "Export calendar" "button"
And I set the field "All events" to "1"
And I set the field "Recent and next 60 days" to "1"
When I click on "Get calendar URL" "button"
Then I should see "&preset_what=all&"
Scenario: Generating calendar URL for course events
Given I follow "This month"
And I click on "Export calendar" "button"
And I set the field "Events related to courses" to "1"
And I set the field "Recent and next 60 days" to "1"
When I click on "Get calendar URL" "button"
Then I should see "&preset_what=courses&"
Scenario: Generating calendar URL for group events
Given I follow "This month"
And I click on "Export calendar" "button"
And I set the field "Events related to groups" to "1"
And I set the field "Recent and next 60 days" to "1"
When I click on "Get calendar URL" "button"
Then I should see "&preset_what=groups&"
Scenario: Generating calendar URL for category events
Given I follow "This month"
And I click on "Export calendar" "button"
And I set the field "Events related to categories" to "1"
And I set the field "Recent and next 60 days" to "1"
When I click on "Get calendar URL" "button"
Then I should see "&preset_what=categories&"
Scenario: Generating calendar URL for user events
Given I follow "This month"
And I click on "Export calendar" "button"
And I set the field "My personal events" to "1"
And I set the field "Recent and next 60 days" to "1"
When I click on "Get calendar URL" "button"
Then I should see "&preset_what=user&"