code: def test_unsupported_evaluation_hook(self):
      class UnsupportedEvaluationHook(
          pfrl.experiments.evaluation_hooks.EvaluationHook
      ):
          support_train_agent = False
          support_train_agent_batch = True
          support_train_agent_async = True
  
          def __call__(
              self,
              env,
              agent,
              evaluator,
              step,
              eval_stats,
              agent_stats,
              env_stats,
          ):
              pass
  
      unsupported_evaluation_hook = UnsupportedEvaluationHook()
  
      with pytest.raises(ValueError) as exception:
          pfrl.experiments.train_agent_with_evaluation(
              agent=mock.Mock(),
              env=mock.Mock(),
              steps=1,
              eval_n_steps=1,
              eval_n_episodes=None,
              eval_interval=1,
              outdir=mock.Mock(),
              evaluation_hooks=[unsupported_evaluation_hook],
          )
  
      assert str(
          exception.value
      ) == "{} does not support train_agent_with_evaluation().".format(
          unsupported_evaluation_hook
      )
  
file_path: pfrl/tests/experiments_tests/test_train_agent.py
imports: import tempfile
  import unittest
  from unittest import mock
  import pytest
  import pfrl
label_desc: Use image node_id 3 for calling the TestTrainAgent obj's underlying member method code with example usage: obj.test_unsupported_evaluation_hook() without return types