Problem/Motivation

So this includes increased coverage, some cleanups (remove unused code) and fixes a bug when running in PHP 7.

It turns out that the sort order when uasort matches 2 strings is undefined. For unclear reasons (probably weird implementation) 5.x swaps the values where PHP 7 and HHVM do not. http://3v4l.org/e6noO

We are not really testing that equal strings behave a specific was but that our sorting works so I expanded the tests to match several cases that mostly cover different ordering of permissions.

Beta phase evaluation

Reference: https://www.drupal.org/core/beta-changes
Issue category Bug because if fixes a test failure in PHP 7
Issue priority Major because PHP 7 support is major?
Unfrozen changes Unfrozen because it only changes tests. Additionally fixes failures for PHP 7 testing.
Disruption Should be none. Tests only.
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

neclimdul’s picture

dawehner’s picture

Status: Active » Reviewed & tested by the community

+1

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed 7a099e8 and pushed to 8.0.x. Thanks!

  • alexpott committed 7a099e8 on 8.0.x
    Issue #2531258 by neclimdul: Improve \Drupal\Tests\user\Unit\...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.