code: def test_inherit():
      theme = Theme({"warning": "red"})
      assert theme.styles["warning"] == Style(color="red")
      assert theme.styles["dim"] == Style(dim=True)
  
file_path: rich/tests/test_theme.py
imports: import io
  import os
  import tempfile
  import pytest
  from rich.style import Style
  from rich.theme import Theme, ThemeStack, ThemeStackError
label_desc: Use image node_id 1 for calling a global function with example usage: test_inherit() without return types