printGroupStructure function

  1. @internal
void printGroupStructure(
  1. DartGroupEntry group, {
  2. int indentation = 0,
})

Recursively prints the structure of the test suite.

Implementation

@internal
void printGroupStructure(DartGroupEntry group, {int indentation = 0}) {
  final indent = ' ' * indentation;
  debugPrint("$indent-- group: '${group.name}'");

  for (final entry in group.entries) {
    if (entry.type == GroupEntryType.test) {
      debugPrint("$indent     -- test: '${entry.name}'");
    } else {
      for (final subgroup in entry.entries) {
        printGroupStructure(subgroup, indentation: indentation + 5);
      }
    }
  }
}