code: def testNestAssertSameStructureCompositeMismatch(
      self, s1, s2, error=ValueError
  ):
      # s1 and s2 have the same structure if expand_composites=False; but
      # different structures if expand_composites=True.
      nest.assert_same_structure(s1, s2, expand_composites=False)
      nest.assert_shallow_structure(s1, s2, expand_composites=False)
      with self.assertRaises(
          error
      ):  # pylint: disable=g-error-prone-assert-raises
          nest.assert_same_structure(s1, s2, expand_composites=True)
  
imports: import gc
  import sys
  import weakref
  from absl.testing import parameterized
  import numpy
  from tensorflow.python.framework import composite_tensor
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import indexed_slices
  from tensorflow.python.framework import sparse_tensor
  from tensorflow.python.framework import test_util
  from tensorflow.python.framework import type_spec
  from tensorflow.python.ops.ragged import ragged_factory_ops
  from tensorflow.python.platform import googletest
  from tensorflow.python.util import nest
label_desc: Use image node_id 5 for calling the CompositeTensorTest obj's underlying member method code with example usage: obj.testNestAssertSameStructureCompositeMismatch(s1, s2, error) without return types