test-bots: Extract common filter out of conditional.

This commit is contained in:
neiljp (Neil Pilgrim) 2018-05-26 16:39:22 -07:00
parent 210caa4a60
commit bda678344f

View file

@ -70,11 +70,11 @@ def main():
cov.start() cov.start()
if options.bots_to_test: if options.bots_to_test:
bots_to_test = filter(lambda bot: bot not in options.exclude, specified_bots = options.bots_to_test
options.bots_to_test)
else: else:
bots_to_test = filter(lambda bot: bot not in options.exclude, specified_bots = available_bots
available_bots)
bots_to_test = filter(lambda bot: bot not in options.exclude, specified_bots)
# Should add a check here that __init__.py is absent if test_*.py is present? # Should add a check here that __init__.py is absent if test_*.py is present?