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

test_yearly_every_20th_monday_forever failing with PHP 8.0.10

    XMLWordPrintable

Details

    • Moppies Kanban

    Description

      With PHP 8.0.10 we've started getting PHPUnit failures when running the following method:

      1) core_calendar_rrule_manager_testcase::test_yearly_every_20th_monday_forever
      Failed asserting that two strings are equal.
      --- Expected
      +++ Actual
      @@ @@
      -'2022-05-16 18:00:00'
      +'2022-05-16 09:00:00'

       

      Eloy has detected that it's due to some changes done in datetime->modify()

      Before PHP 8.0.10… the time is lost when datetime->modify() is used with weekdays. With PHP 8.0.10… it’s kept. https://3v4l.org/PEFkJ

      Attachments

        Activity

          People

            sarjona Sara Arjona (@sarjona)
            sarjona Sara Arjona (@sarjona)
            Carlos Escobedo Carlos Escobedo
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            David Woloszyn, Huong Nguyen, Jake Dallimore, Michael Hawkins, Stevani Andolo
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              13/Sep/21

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 3 hours, 55 minutes
                3h 55m