code: def test_silence_with_bad_input_and_check_warn(
      mock_warn: MagicMock, mock_error: MagicMock
  ) -> None:
      m = Mod(foo=-10)
      with pytest.raises(
          ValueError,
          match="Input to silence should be a warning object",
      ):
          v.silence(cast(Any, "EXT:W"))
      issues = v.check_integrity([m])
      v.process_validation_issues(issues)
      assert not mock_error.called
      assert mock_warn.called
  
imports: from __future__ import annotations
  import pytest
  from typing import Any, cast
  from unittest.mock import MagicMock, patch
  from bokeh.core.properties import Int
  from bokeh.core.validation.check import ValidationIssue, ValidationIssues
  from bokeh.core.validation.issue import Error, Warning
  from bokeh.model import Model
  import bokeh.core.validation
label_desc: Use image node_id 12 for calling a global function with example usage: test_silence_with_bad_input_and_check_warn(mock_warn, mock_error) without return types