class_docstr: Test various APIs that have been changed in 2.0.
code: def testSerializeSparseTensor(self):
      sp_input = tf.SparseTensor(
          indices=tf.constant([[1]], dtype=tf.int64),
          values=tf.constant([2], dtype=tf.int64),
          dense_shape=[2],
      )
  
      with self.cached_session():
          serialized_sp = tf.serialize_sparse(
              sp_input, "serialize_name", tf.string
          )
          self.assertEqual((3,), serialized_sp.shape)
          self.assertTrue(serialized_sp[0].numpy())
  
file_path: tensorflow-upstream/tensorflow/tools/compatibility/testdata/test_file_v1_12.py
imports: import tensorflow.compat.v1
  from tensorflow.python.framework import test_util
  from tensorflow.python.platform import test
label_desc: Use image node_id 4 for calling the TestUpgrade obj's underlying member method code with example usage: obj.testSerializeSparseTensor() without return types