docstr: Test that the hooks are constructed correctly.
docstr_tok: ["Test","that","the","hooks","are","constructed","correctly","."]
code: def test_constructors(self) -> None:
      """
      Test that the hooks are constructed correctly.
      """
      config = {
          "checkpoint_folder": "/test/",
          "input_args": {"foo": "bar"},
          "phase_types": ["train"],
          "checkpoint_period": 2,
      }
      invalid_config = copy.deepcopy(config)
      invalid_config["checkpoint_folder"] = 12
  
      self.constructor_test_helper(
          config=config,
          hook_type=CheckpointHook,
          hook_registry_name="checkpoint",
          invalid_configs=[invalid_config],
      )
  
imports: import copy
  import importlib
  import os
  import shutil
  import tempfile
  import torch
  from classy_vision.generic.util import load_checkpoint
  from classy_vision.hooks import CheckpointHook
  from classy_vision.tasks import build_task
  from classy_vision.trainer import LocalTrainer
  from fvcore.common import file_io
  from fvcore.common.file_io import PathHandler, PathManager
  from test.generic.config_utils import get_fast_test_task_config, get_test_task_config
  from test.generic.hook_test_utils import HookTestBase
label_desc: Use image node_id 3 for calling the TestCheckpointHook obj's underlying member method code with example usage: obj.test_constructors() without return types