code: def test_custom_registered_strategy_to_strategy_flag():
      class CustomCheckpointIO(CheckpointIO):
          def save_checkpoint(self, checkpoint, path):
              pass
  
          def load_checkpoint(self, path):
              pass
  
          def remove_checkpoint(self, path):
              pass
  
      custom_checkpoint_io = CustomCheckpointIO()
  
      # Register the DDP Strategy with your custom CheckpointIO plugin
      StrategyRegistry.register(
          "ddp_custom_checkpoint_io",
          DDPStrategy,
          description="DDP Strategy with custom checkpoint io plugin",
          checkpoint_io=custom_checkpoint_io,
      )
      trainer = Trainer(
          strategy="ddp_custom_checkpoint_io",
          accelerator="cpu",
          devices=2,
      )
  
      assert isinstance(trainer.strategy, DDPStrategy)
      assert trainer.strategy.checkpoint_io == custom_checkpoint_io
  
file_path: pytorch-lightning/tests/tests_pytorch/strategies/test_registry.py
imports: from unittest import mock
  import pytest
  from lightning.pytorch import Trainer
  from lightning.pytorch.plugins import CheckpointIO
  from lightning.pytorch.strategies import DDPStrategy, DeepSpeedStrategy, FSDPStrategy, StrategyRegistry, XLAStrategy
  from tests_pytorch.helpers.runif import RunIf
label_desc: Use image node_id 6 for calling a global function with example usage: test_custom_registered_strategy_to_strategy_flag() without return types