]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
matrix.py: actually generate sorted descriptons 991/head
authorSamuel Just <sjust@redhat.com>
Thu, 1 Dec 2016 19:30:49 +0000 (11:30 -0800)
committerSamuel Just <sjust@redhat.com>
Thu, 1 Dec 2016 20:15:45 +0000 (12:15 -0800)
The existing code compares strings and tuples which, based on what seems
to be happening, is at best counterintuitive and at worst
non-deterministic.

Signed-off-by: Samuel Just <sjust@redhat.com>
teuthology/suite/matrix.py

index f4d91a584848a4f3e0e79b56d3aa2995f4e97d7a..956425d6790d56a124892f9a0159a2011039650b 100644 (file)
@@ -318,9 +318,7 @@ def generate_desc(joinf, result):
     Generates the text description of the test represented by result
     """
     if type(result) is frozenset:
-        ret = []
-        for i in sorted(result):
-            ret.append(generate_desc(joinf, i))
+        ret = sorted([generate_desc(joinf, i) for i in result])
         return '{' + ' '.join(ret) + '}'
     elif type(result) is tuple:
         (item, children) = result