Fix the bug that 'TestGroupResultsViewer' creates unnecessary rows.
authordewei_zhu@apple.com <dewei_zhu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 24 Jan 2018 22:17:33 +0000 (22:17 +0000)
committerdewei_zhu@apple.com <dewei_zhu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 24 Jan 2018 22:17:33 +0000 (22:17 +0000)
commitacc9d3ee8f8d30de23bde62bfaee692e974329cc
tree67ff18528e7d2f301602bee2958e150c0748b3c0
parentf66ec4dca584114e8cee48b99c28ae5d5024b36e
Fix the bug that 'TestGroupResultsViewer' creates unnecessary rows.
https://bugs.webkit.org/show_bug.cgi?id=181967

Reviewed by Ryosuke Niwa.

Fixed a bug caused by a typo in CommitSet.equals, which makes it returns incorrect results for most
comparison between a CommitSet and a MeasurementCommitSet.

MeasurementCommitSet does not have full information for the commits, thus, it cannot build mappings
between root/patch/owner commit/requires build to repository. When querying whether a given repository
needs to be built, MeasurementCommitSet will return undefined. Due to 'undefined != false', this
equality check will fail. Making 'CommitSet.requiresBuildForRepository' defaults to 'false' would fix
this bug.

* public/v3/models/commit-set.js:
(CommitSet.prototype.requiresBuildForRepository): Make it return false when key does not exist
instead of 'undefined'.
(CommitSet.prototype.equals): Fixed the typo that causes the bug.
Use wrapped functions instead of querying the mapping directly.
* unit-tests/commit-set-tests.js: Added unit tests.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@227568 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Websites/perf.webkit.org/ChangeLog
Websites/perf.webkit.org/public/v3/models/commit-set.js
Websites/perf.webkit.org/unit-tests/commit-set-tests.js