- int space = 25 - strlen(i->key);
-
- if (space >= 2) {
- printf(" %s", i->key);
- while (space--)
- putchar(' ');
- } else {
- printf(" %s ", i->key);
+ struct ccanlint *i;
+
+ printf("%s tests:\n", type);
+ /* This makes them print in topological order. */
+ while ((i = get_next_test(tests)) != NULL) {
+ const struct dependent *d;
+ printf(" %-25s %s\n", i->key, i->name);
+ list_del(&i->list);
+ list_for_each(&i->dependencies, d, node)
+ d->dependent->num_depends--;