##// END OF EJS Templates
cvsps: add two more tiebreakers in cscmp...
Augie Fackler -
r22267:90cf454e default
parent child Browse files
Show More
@@ -631,7 +631,19 b' def createchangeset(ui, log, fuzz=60, me'
631 odd.add((l, r))
631 odd.add((l, r))
632 d = -1
632 d = -1
633 break
633 break
634 # By this point, the changesets are sufficiently compared that
635 # we don't really care about ordering. However, this leaves
636 # some race conditions in the tests, so we compare on the
637 # number of files modified and the number of branchpoints in
638 # each changeset to ensure test output remains stable.
634
639
640 # recommended replacement for cmp from
641 # https://docs.python.org/3.0/whatsnew/3.0.html
642 c = lambda x, y: (x > y) - (x < y)
643 if not d:
644 d = c(len(l.entries), len(r.entries))
645 if not d:
646 d = c(len(l.branchpoints), len(r.branchpoints))
635 return d
647 return d
636
648
637 changesets.sort(cscmp)
649 changesets.sort(cscmp)
General Comments 0
You need to be logged in to leave comments. Login now