Revert "suite: do not calculate product on an empty list"

This reverts commit dda7954090.

This commit was causing the number of jobs scheduled per suite to be
multiplied by anywhere from 2 to 7 or more.
This commit is contained in:
Zack Cerza 2013-09-16 18:33:21 -05:00
parent a8e77738af
commit e65d6e2a00

View File

@ -250,13 +250,12 @@ def build_matrix(path):
raw = build_matrix(os.path.join(path, fn))
sublists.append([(combine_path(fn, item[0]), item[1]) for item in raw])
out = []
if sublists:
for sublist in itertools.product(*sublists):
name = '{' + ' '.join([item[0] for item in sublist]) + '}'
val = []
for item in sublist:
val.extend(item[1])
out.append((name, val))
for sublist in itertools.product(*sublists):
name = '{' + ' '.join([item[0] for item in sublist]) + '}'
val = []
for item in sublist:
val.extend(item[1])
out.append((name, val))
return out
else:
# list items