1 |
efrain |
1 |
@mod @mod_forum @forumreport @forumreport_summary
|
|
|
2 |
Feature: Post date columns data available
|
|
|
3 |
In order to determine users' earliest and most recent forum posts
|
|
|
4 |
As a teacher
|
|
|
5 |
I need to view that data in the forum summary report
|
|
|
6 |
|
|
|
7 |
Scenario: Add posts and view accurate summary report
|
|
|
8 |
Given the following "users" exist:
|
|
|
9 |
| username | firstname | lastname | email |
|
|
|
10 |
| teacher1 | Teacher | 1 | teacher1@example.com |
|
|
|
11 |
| student1 | Student | 1 | student1@example.com |
|
|
|
12 |
| student2 | Student | 2 | student1@example.com |
|
|
|
13 |
And the following "courses" exist:
|
|
|
14 |
| fullname | shortname | category |
|
|
|
15 |
| Course 1 | C1 | 0 |
|
|
|
16 |
| Course 2 | C2 | 0 |
|
|
|
17 |
And the following "course enrolments" exist:
|
|
|
18 |
| user | course | role |
|
|
|
19 |
| teacher1 | C1 | editingteacher |
|
|
|
20 |
| student1 | C1 | student |
|
|
|
21 |
| student2 | C1 | student |
|
|
|
22 |
| teacher1 | C2 | editingteacher |
|
|
|
23 |
And the following "activities" exist:
|
|
|
24 |
| activity | name | course | idnumber |
|
|
|
25 |
| forum | forum1 | C1 | forum1C1 |
|
|
|
26 |
| forum | forum2 | C1 | forum2C1 |
|
|
|
27 |
| forum | forum1 | C2 | forum1C2 |
|
|
|
28 |
And the following forum discussions exist in course "Course 1":
|
|
|
29 |
| user | forum | name | message | created |
|
|
|
30 |
| teacher1 | forum1 | discussion1 | t1 earliest | ##2018-01-02 09:00:00## |
|
|
|
31 |
| teacher1 | forum1 | discussion2 | t1 between | ##2018-03-27 10:00:00## |
|
|
|
32 |
| teacher1 | forum2 | discussion3 | t1 other forum | ##2018-01-01 11:00:00## |
|
|
|
33 |
| student1 | forum1 | discussion4 | s1 latest | ##2019-03-27 13:00:00## |
|
|
|
34 |
| student2 | forum2 | discussion5 | s2 other forum | ##2018-03-27 09:00:00## |
|
|
|
35 |
And the following forum replies exist in course "Course 1":
|
|
|
36 |
| user | forum | discussion | message | created |
|
|
|
37 |
| teacher1 | forum1 | discussion1 | t1 between | ##2018-01-02 10:30:00## |
|
|
|
38 |
| teacher1 | forum1 | discussion2 | t1 latest | ##2019-09-01 07:00:00## |
|
|
|
39 |
| teacher1 | forum2 | discussion3 | t1 other forum | ##2019-09-12 08:00:00## |
|
|
|
40 |
| student1 | forum1 | discussion1 | s1 earliest | ##2019-03-27 04:00:00## |
|
|
|
41 |
| student2 | forum2 | discussion3 | s2 other forum | ##2018-03-27 10:00:00## |
|
|
|
42 |
And the following forum discussions exist in course "Course 2":
|
|
|
43 |
| user | forum | name | message | created |
|
|
|
44 |
| teacher1 | forum1 | discussion1 | t1 other course | ##2017-01-01 03:00:00## |
|
|
|
45 |
| teacher1 | forum1 | discussion2 | t1 other course | ##2019-09-13 23:59:00## |
|
|
|
46 |
When I am on the forum1C1 "forum activity" page logged in as teacher1
|
|
|
47 |
And I navigate to "Reports" in current page administration
|
|
|
48 |
Then "Teacher 1" row "Earliest post" column of "forumreport_summary_table" table should contain "Tuesday, 2 January 2018, 9:00"
|
|
|
49 |
Then "Teacher 1" row "Most recent post" column of "forumreport_summary_table" table should contain "Sunday, 1 September 2019, 7:00"
|
|
|
50 |
Then "Student 1" row "Earliest post" column of "forumreport_summary_table" table should contain "Wednesday, 27 March 2019, 4:00"
|
|
|
51 |
Then "Student 1" row "Most recent post" column of "forumreport_summary_table" table should contain "Wednesday, 27 March 2019, 1:00"
|
|
|
52 |
Then "Student 2" row "Earliest post" column of "forumreport_summary_table" table should contain "-"
|
|
|
53 |
Then "Student 2" row "Most recent post" column of "forumreport_summary_table" table should contain "-"
|