This is an archive of the discontinued LLVM Phabricator instance.

[LNT] Python 3 support: stable showtests output
ClosedPublic

Authored by thopre on Sep 30 2019, 6:55 AM.

Details

Summary

lnt showtests output depends on the iteration order of a set, which has
no guarantee whatsoever. This makes the result of test
tests/lnttool/showtests.shtest unstable in particular accross Python 2
and 3. This commit makes the lnt.tests constructor return a new sorted
list instead of the set, thus guaranteeing a stable output of lnt
showtests. It also lists tests in alphabetical order which makes it
nicer for users.

Event Timeline

thopre created this revision.Sep 30 2019, 6:55 AM

My general impression is that this is harmless. As it is, there is no other key available to sort on. @cmatthews, can you confirm?

thopre added a comment.Oct 9 2019, 1:49 AM

My general impression is that this is harmless. As it is, there is no other key available to sort on. @cmatthews, can you confirm?

Ping @cmatthews ?

cmatthews accepted this revision.Oct 9 2019, 11:16 AM

Yeah, that seems fine.

This revision is now accepted and ready to land.Oct 9 2019, 11:16 AM
thopre closed this revision.Oct 10 2019, 3:54 AM