Uploaded image for project: 'Moodle Community Sites'
  1. Moodle Community Sites
  2. MDLSITE-2398

Detect assertions in methods not named test*

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Low
    • Resolution: Unresolved
    • Component/s: Integration
    • Labels:
      None

      Description

      Simon discovered in MDL-39572 that we had some dml tests which weren't being run because the method was not prefixed with test_ as required by phpunit.

      This issue is to see if we could detect this on the CI server.

      This is tricky/perhaps impossible because there are often utility methods, but one technique could be to search for methods with assertions in them and warn about it (even if there are exceptions, we could have a list of them and deafult assume all methods with assertions should be tests).

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              stronk7 Eloy Lafuente (stronk7)
              Reporter:
              poltawski Dan Poltawski
              Participants:
              Component watchers:
              Eloy Lafuente (stronk7)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated: