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

PHPUnit failure on Oracle due to erroneous default sorting

XMLWordPrintable

    • MOODLE_32_STABLE
    • MOODLE_32_STABLE
    • MDL-56228-master
    • Hide

      This is just a simple regression test

      1. Set up oracle docker instance and the the oracle oci driver for php (see here for Ubuntu derivatives )
      2. Run the following test a few times and make sure it passes (no regression)

        vendor/bin/phpunit mod_data_generator_testcase mod/data/tests/generator_test.php
        

      Show
      This is just a simple regression test Set up oracle docker instance and the the oracle oci driver for php ( see here for Ubuntu derivatives ) Run the following test a few times and make sure it passes (no regression) vendor/bin/phpunit mod_data_generator_testcase mod/data/tests/generator_test.php

      Testing a library upgrade, I came across this failure (using the moodle oracle docker instance):

      There was 1 failure:
       
      1) mod_data_generator_testcase::test_create_entry
      Failed asserting that two strings are equal.
      --- Expected
      +++ Actual
      @@ @@
      -'menu1'
      +'opt1##opt2##opt3##opt4'
       
      /home/jake/moodledata/omaster/moodle/mod/data/tests/generator_test.php:221
      /home/jake/moodledata/omaster/moodle/lib/phpunit/classes/advanced_testcase.php:80
       
      To re-run:
       vendor/bin/phpunit mod_data_generator_testcase mod/data/tests/generator_test.php
       
      FAILURES!
      Tests: 3, Assertions: 70, Failures: 1.
      

      The first run passed, but subsequent runs hit this error every time. The problem is that the default sort by (which should be ASC), isn't functioning properly.

            jaked Jake Dallimore
            jaked Jake Dallimore
            Rajesh Taneja Rajesh Taneja
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Simey Lameze Simey Lameze
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.