|
46 | 46 | Then I should see "This is the answer message"
|
47 | 47 | And I should see "This is the question message"
|
48 | 48 |
|
49 |
| - Scenario: Setting up the limited answer mode, the times need to be in order and in the future. |
| 49 | + Scenario: Setting up the limited answer mode, the times need to be in the right order |
50 | 50 | Given the following "activities" exist:
|
51 | 51 | | activity | name | intro | course | idnumber |
|
52 | 52 | | moodleoverflow | Test Moodleoverflow | Test moodleoverflow description | C1 | 1 |
|
|
55 | 55 | And I follow "Test Moodleoverflow"
|
56 | 56 | And I follow "Settings"
|
57 | 57 | And I follow "Limited Answer Mode"
|
58 |
| - And |
59 |
| - And I pause |
| 58 | + And I click on "la_starttime[enabled]" "checkbox" |
| 59 | + And I set the following fields to these values: |
| 60 | + | id_la_starttime_day | ##tomorrow##%d## | |
| 61 | + | id_la_starttime_month | ##tomorrow##%B## | |
| 62 | + | id_la_starttime_year | ##tomorrow##%Y## | |
| 63 | + | id_la_starttime_hour | 12 | |
| 64 | + | id_la_starttime_minute | 30 | |
| 65 | + And I click on "la_endtime[enabled]" "checkbox" |
| 66 | + And I set the following fields to these values: |
| 67 | + | id_la_endtime_day | ##yesterday##%d## | |
| 68 | + | id_la_endtime_month | ##yesterday##%B## | |
| 69 | + | id_la_endtime_year | ##yesterday##%Y## | |
| 70 | + | id_la_endtime_hour | 12 | |
| 71 | + | id_la_endtime_minute | 30 | |
| 72 | + When I press "Save and display" |
| 73 | + And I follow "Limited Answer Mode" |
| 74 | + And I click on "#collapseElement-5" "css_element" |
| 75 | + Then I should see "End time must be in the future" |
| 76 | + And I should see "The end time must be after the start time" |
| 77 | + |
| 78 | + Scenario: Setting up the limited answer mode, the start times need to be in the future |
| 79 | + Given the following "activities" exist: |
| 80 | + | activity | name | intro | course | idnumber | |
| 81 | + | moodleoverflow | Test Moodleoverflow | Test moodleoverflow description | C1 | 1 | |
| 82 | + And I log in as "teacher1" |
| 83 | + And I am on "Course 1" course homepage |
| 84 | + And I follow "Test Moodleoverflow" |
| 85 | + And I follow "Settings" |
| 86 | + And I follow "Limited Answer Mode" |
| 87 | + And I click on "la_starttime[enabled]" "checkbox" |
| 88 | + And I set the following fields to these values: |
| 89 | + | id_la_starttime_day | ##yesterday##%d## | |
| 90 | + | id_la_starttime_month | ##yesterday##%B## | |
| 91 | + | id_la_starttime_year | ##yesterday##%Y## | |
| 92 | + | id_la_starttime_hour | 12 | |
| 93 | + | id_la_starttime_minute | 30 | |
| 94 | + When I press "Save and display" |
| 95 | + And I follow "Limited Answer Mode" |
| 96 | + And I click on "#collapseElement-5" "css_element" |
| 97 | + Then I should see "Start time must be in the future" |
0 commit comments