def test_get_debug_values_exc():
 prev_value = config.compute_test_value
 try:
  config.compute_test_value = 'raise'
  x = T.vector()
  try:
   for x_val in op.get_debug_values(x):
    assert False
   raised = False
  except AttributeError:
   raised = True
  assert raised
 finally:
  config.compute_test_value = prev_value

def test_get_debug_values_exc ( ) : prev_value = config . compute_test_value try : config . compute_test_value = 'raise' x = T . vector ( ) try : for x_val in op . get_debug_values ( x ) : assert False raised = False except AttributeError : raised = True assert raised finally : config . compute_test_value = prev_value
tests that get_debug_value raises an exception when debugger is set to raise and a value is missing .