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

Uses of M.str.{component}.{identifier} should be reviewed and converted to M.util.get_string where possible to avoid needless JS errors from missing strings

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Fixed
    • Icon: Minor Minor
    • 2.9
    • 2.1
    • JavaScript
    • MOODLE_21_STABLE
    • MOODLE_29_STABLE
    • MDL-28286-master
    • Hide

      In reality, this is pretty irritating to fully test. Behat will cover some of it, but many of the changes are to error strings or exception strings that you will struggle to force through the UI.

      Running behat will be of use, but will not cover everything. Most are trivial changes, but the following areas could do with general testing for string issues:

      1. Availability builder
      2. File picker
      3. File manager
      4. Enrolment

      The things you are looking for are JS errors in the console; and missing strings.

      I also recommend carefully reading each of the changes in the diff. For the most part they consist of replacing:

      M.str.component.identifier
      

      with

      M.util.get_string('identifier', 'component')
      

      Show
      In reality, this is pretty irritating to fully test. Behat will cover some of it, but many of the changes are to error strings or exception strings that you will struggle to force through the UI. Running behat will be of use, but will not cover everything. Most are trivial changes, but the following areas could do with general testing for string issues: Availability builder File picker File manager Enrolment The things you are looking for are JS errors in the console; and missing strings. I also recommend carefully reading each of the changes in the diff. For the most part they consist of replacing: M.str.component.identifier with M.util.get_string('identifier', 'component')
    • FRONTEND Sprint 15

      Just an obvious win - we now have M.util.get_string in javascript-static - it would be nice to use it to avoid any missing string errors.

      Moodle admins - it may be nice to have a couple of new components `JavaScript` and `Page and Output`

      Cheers
      Sam

            dobedobedoh Andrew Lyons
            samhemelryk Sam Hemelryk
            Frédéric Massart Frédéric Massart
            Sam Hemelryk Sam Hemelryk
            Ankit Agarwal Ankit Agarwal
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved:

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