class_docstr: Most tests done in the base class LinearOperatorDerivedClassTest.
class_docstr_tok: ["Most","tests","done","in","the","base","class","LinearOperatorDerivedClassTest","."]
code: def test_assert_positive_definite_raises_for_negative_real_eigvalues(
      self,
  ):
      with self.cached_session():
          diag_x = [1.0, -2.0]
          diag_y = [
              0.0,
              0.0,
          ]  # Imaginary eigenvalues should not matter.
          diag = math_ops.complex(diag_x, diag_y)
          operator = linalg.LinearOperatorDiag(diag)
  
          # is_self_adjoint should not be auto-set for complex diag.
          self.assertTrue(operator.is_self_adjoint is None)
          with self.assertRaisesOpError(
              "non-positive real.*not positive definite"
          ):
              operator.assert_positive_definite().run()
  
imports: from tensorflow.python.framework import config
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import linalg_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops import random_ops
  from tensorflow.python.ops import variables
  from tensorflow.python.ops.linalg import linalg
  from tensorflow.python.ops.linalg import linear_operator_test_util
  from tensorflow.python.platform import test
label_desc: Use image node_id 6 for calling the LinearOperatorDiagTest obj's underlying member method code with example usage: obj.test_assert_positive_definite_raises_for_negative_real_eigvalues() without return types