I’d like to give the run method a default argument so that it will run all test cases if no test_cases argument is given. How would you recommend I do this?
from collections import OrderedDict
class TestCase(OrderedDict):
def run(self, test_cases):
for test_case_name in test_cases:
self[test_case_name].run()
You can replace the default
Noneby another immutable object, such as string or integer.