Homec4science

Make the libphutil library map test failure more readable

Authored by epriestley <git@epriestley.com> on Mar 1 2016, 15:15.

Description

Make the libphutil library map test failure more readable

Summary:
Ref T10457. This is an upstream quality-of-life fix.

Currently, if the map rebuild test fails it generates about 9,000 lines of output in a huge diff of the two values. This is technically fine, but pretty hard to read.

Instead, compute a smaller difference showing only changed keys, since we never care about the values when this failure occurs (and barely care about the keys).

Test Plan:

   FAIL  PhabricatorLibraryTestCase::testLibraryMap
Assertion failed, expected 'true' (at PhutilLibraryTestCase.php:51): The library map is out of date. Rebuild it with `arc liberate`.
These entries differ: class.NewExampleClass.

ACTUAL VALUE
false

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T10457

Differential Revision: https://secure.phabricator.com/D15370

Details

Committed
epriestley <git@epriestley.com>Mar 1 2016, 15:51
Pushed
aubortMar 17 2017, 12:03
Parents
rPHU6ef9295e388d: Declare tokenCache on AASTNode
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHUad3f475c8c13: Make the libphutil library map test failure more readable (authored by epriestley <git@epriestley.com>).Mar 1 2016, 15:51