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

Fix all (now) wrong namespace uses within **/tests directories

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.6.6, 3.7.2, 3.8
    • Fix Version/s: None
    • Component/s: General, Unit tests
    • Labels:
      None
    • Affected Branches:
      MOODLE_36_STABLE, MOODLE_37_STABLE, MOODLE_38_STABLE

      Description

      With MDLSITE-4800, rules about how to use namespaces within **/tests directories have been agreed

      Right now there are some uses in core violating that agreement:

      $ ag '^namespace' | grep _test.php
      blocks/html/tests/search_content_test.php:25:namespace block_html;
      admin/tool/httpsreplace/tests/httpsreplace_test.php:25:namespace tool_httpsreplace\tests;
      grade/grading/form/guide/tests/generator_test.php:26:namespace tests\gradingform_guide;
      grade/grading/form/rubric/tests/privacy_test.php:26:namespace tests\gradingform_rubric;
      grade/grading/form/rubric/tests/generator_test.php:26:namespace tests\gradingform_rubric;
      grade/grading/tests/generator_test.php:26:namespace tests\core_grading;
      search/tests/skip_future_documents_iterator_test.php:26:namespace core_search;
      search/tests/external_test.php:25:namespace core_search;
      webservice/soap/tests/wsdl_test.php:25:namespace webservice_soap;
      lib/form/tests/external_test.php:26:namespace core_form;
      lib/form/tests/filetypes_util_test.php:26:namespace core_form;
      mod/assign/tests/privacy_test.php:25:namespace mod_assign\tests;
      

      This issue is about to fix all them and make core compliant.

      Ciao

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            stronk7 Eloy Lafuente (stronk7)
            Participants:
            Component watchers:
            Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: