code: def test_illegal_input(runhistory):
      with pytest.raises(
          TypeError, match="Configuration must not be None."
      ):
          runhistory.add(
              config=None,
              cost=1.23,
              time=2.34,
              status=StatusType.SUCCESS,
          )
  
      with pytest.raises(
          TypeError,
          match="Configuration is not of type Configuration, but .*str.*",
      ):
          runhistory.add(
              config="abc",
              cost=1.23,
              time=2.34,
              status=StatusType.SUCCESS,
          )
  
imports: from __future__ import annotations
  import os
  import pickle
  import tempfile
  import pytest
  from smac.runhistory.runhistory import RunHistory, TrialKey
  from smac.runner.abstract_runner import StatusType
label_desc: Use image node_id 5 for calling a global function with example usage: test_illegal_input(runhistory) without return types