You must have enabled availability support at system level for all tests.
Some background: This change does not affect the logic about whether users are permitted to access/see activities, which was always based on time values in seconds. The change only affects how the settings are edited and displayed. That's why this test does not include 'can the user access...' type steps.
Test upgrade step:
1. Before running the system upgrade, ensure that you have some activities with an 'available until' date set, for example to 14 October. (Which means they will be available until 14 October at 23:59:59.)
2. Run the system upgrade and go back to the course
- Verify that that the activity still displays as available until 14 October.
3. Edit the activity.
- Verify that the 'until' date now shows as 15 October 00:00
Editing change
4. Add a new activity (any kind) on the course.
- Verify that the available from/until dates are both disabled.
- Verify that the value for these dates is 0:00 on current day. (This allows users to more easily take advantage of the 'shorthand' date-only display.)
Test display change
5. Add a number of activities with the following from/to dates and verify that the text is the same as given here. I have written them in the format [from date] to [to date] = [expected text]. The result may vary in specific details based on your time format - this is the spectacularly horrible format that, I think, is Moodle default. (01:05 PM? Really? I think you mean 1.05 pm, if you must insist in not using 24-hour clock... anyhow, separate issue.)
a. 14 Oct 13:05 to 17 Oct 12:10 = Available from 14 October 2011, 01:05 PM to 17 October 2011, 12:10 PM.
b. 14 Oct 0:00 to 17 Oct 12:10 = Available from 14 October 2011 to 17 October 2011, 12:10 PM.
c.14 Oct 13:05 to 18 Oct 0:00 = Available from 14 October 2011, 01:05 PM to 17 October 2011.'
d. 14 Oct 0:00 to 18 Oct 0:00 = Available from 14 October 2011 to 17 October 2011.
e. 14 Oct 0:00 to 15 Oct 0:00 = Available on 14 October 2011.
f. 14 Oct 13:05 to 15 Oct 0:00 = Available from 14 October 2011, 01:05 PM to 15 October 2011, 12:00 AM.
g. 14 Oct 0:00 to 14 Oct 12:05 = Available from 14 October 2011, 12:00 AM to 14 October 2011, 12:05 PM.
h. 14 Oct 13:05 to [disabled] = Available from 14 October 2011, 01:05 PM.
i. 14 Oct 0:00 to [disabled] = Available from 14 October 2011.
j. [disabled] to 14 Oct 13:05 = Available until 14 October 2011, 01:05 PM.
k [disabled] to 15 Oct 0:00 = Available until 14 October 2011.
(yes I did this during development - I found it quickest to add labels.)