prepareCleanup method

void prepareCleanup()

Record which runCiCleanupTopDirs are missing before the tests and the build (and devBuildSetup), the ones then created are deleted by cleanup.

Implementation

void prepareCleanup() {
  if (isWorkspaceRoot || options.noCleanup) {
    return;
  }
  _cleanupMissingTopDirs = runCiCleanupTopDirs
      .where(
        (dir) =>
            FileSystemEntity.typeSync(join(path, dir), followLinks: false) ==
            FileSystemEntityType.notFound,
      )
      .toList();
}