class_docstr: Unit tests for policy gradient.
class_docstr_tok: ["Unit","tests","for","policy","gradient","."]
code: def test_init_unsupported_model(self, mock_parameters):
      action_space = spaces.Discrete(2)
      observation_space = spaces.Box(0, 1, (1,))
      self._setup_parameters(mock_parameters.return_value)
  
      # Verify sut can be constructed.
      sut = ActorCritic("", observation_space, action_space)
  
      mock_parameters.return_value.policy_representation = "undefined"
      self.assertRaises(
          ValueError, ActorCritic, "", observation_space, action_space
      )
  
      mock_parameters.return_value.policy_representation = "nn"
      mock_parameters.return_value.value_function_representation = (
          "undefined"
      )
      self.assertRaises(
          ValueError, ActorCritic, "", observation_space, action_space
      )
  
imports: import unittest
  import cntk.contrib.deeprl.tests.spaces
  import numpy
  from cntk.contrib.deeprl.agent.policy_gradient import ActorCritic
  from cntk.layers import Dense
  from cntk.losses import cross_entropy_with_softmax
  from cntk.ops import input_variable, placeholder
label_desc: Use image node_id 5 for calling the PolicyGradientTest obj's underlying member method code with example usage: obj.test_init_unsupported_model(mock_parameters) without return types