code: def test_rich_model_summary_callback():
      trainer = Trainer(callbacks=RichProgressBar())
  
      assert any(
          isinstance(cb, RichModelSummary) for cb in trainer.callbacks
      )
      assert isinstance(trainer.progress_bar_callback, RichProgressBar)
  
file_path: pytorch-lightning/tests/tests_pytorch/callbacks/test_rich_model_summary.py
imports: from typing import Any
  from unittest import mock
  import pytest
  import torch
  from lightning.pytorch import Trainer
  from lightning.pytorch.callbacks import RichModelSummary, RichProgressBar
  from lightning.pytorch.demos.boring_classes import BoringModel
  from lightning.pytorch.utilities.model_summary import summarize
  from tests_pytorch.helpers.runif import RunIf
label_desc: Use image node_id 1 for calling a global function with example usage: test_rich_model_summary_callback() without return types