class_docstr: Make sure the package is alive.
code: def _check_directory(
      self, listname, thing_list, thing_dir, thing_key, ignore=None
  ):
      if ignore is None:
          ignore = []
      dirs = testing_utils.git_ls_dirs()
      # get only directories directly in the thing directory
      dirs = [d for d in dirs if os.path.dirname(d) == thing_dir]
      # just the folder names
      dirs = [os.path.basename(d) for d in dirs]
      # skip the allowlist
      dirs = [d for d in dirs if d not in ignore]
      # make it a set
      dirs = set(dirs)
  
      # and the list of thing names
      thing_names = {
          thing[thing_key].split(":")[0] for thing in thing_list
      }
  
      errors = []
      # items with a directory but not a listing
      for name in dirs - thing_names:
          errors.append(
              "Directory {}/{} exists, but isn't in {}".format(
                  thing_dir, name, listname
              )
          )
      for name in thing_names - dirs:
          errors.append(
              "{} exists in {}, but {}/{} isn't a directory".format(
                  name, listname, thing_dir, name
              )
          )
  
      if errors:
          self.assertTrue(False, "\n".join(errors))
  
file_path: ParlAI/tests/test_zootasks.py
imports: import os
  import unittest
  import pytest
  import parlai.utils.testing
  from parlai.zoo.model_list import model_list
  from parlai.tasks.task_list import task_list
label_desc: Use image node_id 7 for calling the TestZooAndTasks obj's underlying member method code with example usage: obj._check_directory(listname, thing_list, thing_dir, thing_key, ignore) without return types