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

testing_util::get_git_hash() don't work when HEAD points to a hash

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide

      Test 1

      1. Point your clone to master integration if you haven't done it yet
      2. Open .git/HEAD and ensure there is a "ref: refs/heads/BRANCH_NAME" to a branch
      3. Run vendor/bin/phpunit or vendor/bin/behat
      4. After the dbtype you SHOULD see a git hash

      Test 2

      1. Point your clone to a has rather than a branch
        • git checkout whatever_hash_after_this_has_been_integrated
      2. Run vendor/bin/phpunit or vendor/bin/behat
      3. After the dbtype you SHOULD see a git hash
      Show
      Test 1 Point your clone to master integration if you haven't done it yet Open .git/HEAD and ensure there is a "ref: refs/heads/BRANCH_NAME" to a branch Run vendor/bin/phpunit or vendor/bin/behat After the dbtype you SHOULD see a git hash Test 2 Point your clone to a has rather than a branch git checkout whatever_hash_after_this_has_been_integrated Run vendor/bin/phpunit or vendor/bin/behat After the dbtype you SHOULD see a git hash
    • Affected Branches:
      MOODLE_25_STABLE, MOODLE_26_STABLE
    • Fixed Branches:
      MOODLE_25_STABLE, MOODLE_26_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-43355_master

      Description

      If HEAD is pointing to a branch get_git_hash works as expected, but if it is pointing to a git hash it doesn't as the hash is not 'ref: ' prefixed.

        Attachments

          Activity

            People

            Assignee:
            dmonllao David Monllaó
            Reporter:
            dmonllao David Monllaó
            Peer reviewer:
            Petr Skoda
            Integrator:
            Sam Hemelryk
            Tester:
            Jason Fowler
            Participants:
            Component watchers:
            Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

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