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

Group all the PHPUnit tests related to H5P

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • 4.2
    • H5P
    • MOODLE_402_STABLE

      It would be great to create a mechanism to run all the PHPUnit tests using H5P (different testsuites can be added too but, in that particular case, that's writing a lot). In MDL-76691, the following commit was added, to include all the folders to the H5P testsuite:

          <testsuite name="core_h5p_testsuite">
      +      <directory suffix="_test.php">contentbank/contenttype/h5p/tests</directory>
      +      <directory suffix="_test.php">filter/displayh5p/tests</directory>
      +      <directory suffix="_test.php">lib/editor/atto/plugins/h5p/tests</directory>
      +      <directory suffix="_test.php">lib/editor/tiny/plugins/h5p/tests</directory>
             <directory suffix="_test.php">h5p/tests</directory>
      +      <directory suffix="_test.php">mod/h5pactivity/tests</directory>
      +      <directory suffix="_test.php">repository/contentbank/tests</directory>
          </testsuite>

       

      However, there are other approaches which fit better, like the @group label:

      namespace mod_h5pactivity\event;
       
      /**
       * @group h5p
       */
      class course_module_instance_list_viewed_test extends advanced_testcase {
          // ...
      }
      

      Then:

      ./vendor/bin/phpunit --group h5p

      This issue is to add support to this.

            Unassigned Unassigned
            sarjona Sara Arjona (@sarjona)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

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