code: def test_checkpoint_dir_deprecation():
      def train_fn(config, checkpoint_dir=None):
          pass
  
      with pytest.raises(
          DeprecationWarning, match=r".*checkpoint_dir.*"
      ):
          tune.run(train_fn)
  
      def train_fn(config, reporter):
          pass
  
      with pytest.raises(DeprecationWarning, match=r".*reporter.*"):
          tune.run(train_fn)
  
      def train_fn(config):
          tune.report(test=1)
  
      with pytest.raises(DeprecationWarning, match=r".*tune\.report.*"):
          tune.run(train_fn, fail_fast="raise")
  
      def train_fn(config):
          with tune.checkpoint_dir(step=1) as _:
              pass
  
      with pytest.raises(
          DeprecationWarning, match=r".*tune\.checkpoint_dir.*"
      ):
          tune.run(train_fn, fail_fast="raise")
  
label_desc: Use image node_id 1 for calling a global function with example usage: test_checkpoint_dir_deprecation() without return types