def find_all_tests(suite):
 suites = [suite]
 while suites:
  s = suites.pop()
  try:
   suites.extend(s)
  except TypeError:
   (yield (s, ('%s.%s.%s' % (s.__class__.__module__, s.__class__.__name__, s._testMethodName))))

def find_all_tests ( suite ) : suites = [ suite ] while suites : s = suites . pop ( ) try : suites . extend ( s ) except TypeError : ( yield ( s , ( '%s.%s.%s' % ( s . __class__ . __module__ , s . __class__ . __name__ , s . _testMethodName ) ) ) )
yields all the tests and their names from a given suite .