Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-66558

Relative dates: behat test edge case failure

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.8
    • 3.8
    • Course

    Description

      There's a current failure in the mod/assign/tests/behat/relative_dates.feature file.

      The intention was to have an assignment valid for one month and a user (student 2) who started on the first day of the current month and who would have access to this assignment. Howeverm because the 'valid for one month' steps were using 'first and last days of -2 months' syntax, the number of days could vary. Thus, we ended up in a situation on August 30 (today) where the -2 months start and end (for June) gives an assignment valid for only 30 days. Which means it expires on August 30 for the student starting in August - about 5 seconds before the student logs in during the behat test.

      Solution:

      Change all the ranges to be so large that we don't hit these 'number of days in a month' type problems.

      Attachments

        Issue Links

          Activity

            People

              jaked Jake Dallimore
              jaked Jake Dallimore
              Jun Pataleta Jun Pataleta
              Adrian Greeve Adrian Greeve
              CiBoT CiBoT
              Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Laurent David, Sara Arjona (@sarjona)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                18/Nov/19

                Time Tracking

                  Estimated:
                  Original Estimate - 0 minutes
                  0m
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 37 minutes
                  37m