| [ Index ] |
PHP Cross Reference of moodle-2.8 |
[Summary view] [Print] [Text view]
1 @mod @mod_choice 2 Feature: Multiple option choice response 3 In order to ask questions as a choice of multiple responses 4 As a teacher 5 I need to add choice activities to courses with multiple options enabled 6 7 @javascript 8 Scenario: Complete a choice with multiple options enabled 9 Given the following "users" exist: 10 | username | firstname | lastname | email | 11 | teacher1 | Teacher | 1 | [email protected] | 12 | student1 | Student | 1 | [email protected] | 13 And the following "courses" exist: 14 | fullname | shortname | category | 15 | Course 1 | C1 | 0 | 16 And the following "course enrolments" exist: 17 | user | course | role | 18 | teacher1 | C1 | editingteacher | 19 | student1 | C1 | student | 20 And I log in as "teacher1" 21 And I follow "Course 1" 22 And I turn editing mode on 23 And I add a "Choice" to section "1" and I fill the form with: 24 | Choice name | Choice name | 25 | Description | Choice Description | 26 | Allow more than one choice to be selected | Yes | 27 | option[0] | Option 1 | 28 | option[1] | Option 2 | 29 And I log out 30 When I log in as "student1" 31 And I follow "Course 1" 32 And I choose options "Option 1","Option 2" from "Choice name" choice activity 33 Then I should see "Your selection: Option 1; Option 2" 34 And I should see "Your choice has been saved" 35 36 @javascript 37 Scenario: Complete a choice with multiple options enabled and limited responses set 38 Given the following "users" exist: 39 | username | firstname | lastname | email | 40 | teacher1 | Teacher | 1 | [email protected] | 41 | student1 | Student | 1 | [email protected] | 42 | student2 | Student | 2 | [email protected] | 43 And the following "courses" exist: 44 | fullname | shortname | category | 45 | Course 1 | C1 | 0 | 46 And the following "course enrolments" exist: 47 | user | course | role | 48 | teacher1 | C1 | editingteacher | 49 | student1 | C1 | student | 50 | student2 | C1 | student | 51 And I log in as "teacher1" 52 And I follow "Course 1" 53 And I turn editing mode on 54 And I add a "Choice" to section "1" and I fill the form with: 55 | Choice name | Choice name | 56 | Description | Choice Description | 57 | Allow more than one choice to be selected | Yes | 58 | Limit the number of responses allowed | 1 | 59 | option[0] | Option 1 | 60 | limit[0] | 1 | 61 | option[1] | Option 2 | 62 | limit[1] | 1 | 63 | option[2] | Option 3 | 64 | limit[2] | 1 | 65 And I log out 66 When I log in as "student1" 67 And I follow "Course 1" 68 And I choose options "Option 1","Option 2" from "Choice name" choice activity 69 Then I should see "Your selection: Option 1; Option 2" 70 And I should see "Your choice has been saved" 71 And I log out 72 And I log in as "student2" 73 And I follow "Course 1" 74 And I follow "Choice name" 75 And I should see "Option 1 (Full)" 76 And I should see "Option 2 (Full)" 77 And I should see "Option 3" 78 And the "#choice_1" "css_element" should be disabled 79 And the "#choice_2" "css_element" should be disabled 80 And the "#choice_3" "css_element" should be enabled
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| Generated: Fri Nov 28 20:29:05 2014 | Cross-referenced by PHPXref 0.7.1 |