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

Undefined auth_name in tool_mobile external test

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      1. Run tool_mobile tests.

        mdk phpunit -r -s tool_mobile
        

      2. Confirm that everything passes.
      Show
      Run tool_mobile tests. mdk phpunit -r -s tool_mobile Confirm that everything passes.
    • Workaround:
      Hide

      Add set_config('auth_name', 'CAS', 'auth_cas'); to line 125 of the admin/tool/mobile/tests/externallib_test.php file

      Show
      Add set_config('auth_name', 'CAS', 'auth_cas'); to line 125 of the admin/tool/mobile/tests/externallib_test.php file
    • Affected Branches:
      MOODLE_36_STABLE, MOODLE_37_STABLE, MOODLE_38_STABLE, MOODLE_39_STABLE
    • Fixed Branches:
      MOODLE_37_STABLE, MOODLE_38_STABLE
    • Pull Master Branch:
      MDL-67148-master

      Description

      When the PHP LDAP module is not installed, the tool_mobile PHPUnit external test throws an error:

      vendor/bin/phpunit "tool_mobile_external_testcase" admin/tool/mobile/tests/externallib_test.php

      (1) tool_mobile_external_testcase::test_get_public_config
      Undefined property: stdClass::$auth_name
      auth/cas/auth.php:386
      lib/authlib.php:731
      admin/tool/mobile/classes/api.php:205
      admin/tool/mobile/classes/external.php:125
      admin/tool/mobile/tests/externallib_test.php:147
      lib/phpunit/classes/advanced_testcase.php:80

      The auth_name configuration setting of auth_cas is not set when the PHP LDAP module is absent.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jpataleta Jun Pataleta
              Reporter:
              rdebleu Renaat Debleu
              Peer reviewer:
              Carlos Escobedo
              Integrator:
              Eloy Lafuente (stronk7)
              Tester:
              Eloy Lafuente (stronk7)
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan, Andrew Nicols, Dongsheng Cai, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                13/Jan/20

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 hour, 20 minutes
                  1h 20m