code: def test_train_step_no_return(tmpdir, single_cb: bool):
      """Tests that only training_step can be used."""
  
      class CB(Callback):
          def on_train_batch_end(self, trainer, pl_module, outputs, *_):
              assert "loss" in outputs
  
          def on_validation_batch_end(
              self, trainer, pl_module, outputs, *_
          ):
              assert "x" in outputs
  
          def on_test_batch_end(self, trainer, pl_module, outputs, *_):
              assert "x" in outputs
  
      class TestModel(BoringModel):
          def on_train_batch_end(self, outputs, *_):
              assert "loss" in outputs
  
          def on_validation_batch_end(self, outputs, *_):
              assert "x" in outputs
  
          def on_test_batch_end(self, outputs, *_):
              assert "x" in outputs
  
      model = TestModel()
  
      trainer = Trainer(
          callbacks=CB() if single_cb else [CB()],
          default_root_dir=tmpdir,
          limit_train_batches=2,
          limit_val_batches=2,
          max_epochs=1,
          log_every_n_steps=1,
          enable_model_summary=False,
      )
  
      assert any(isinstance(c, CB) for c in trainer.callbacks)
  
      trainer.fit(model)
  
label_desc: Use image node_id 1 for calling a global function with example usage: test_train_step_no_return(tmpdir, single_cb) without return types