code: def test_iterator_next_with_catching_stop_iteration(self):
      # Graph ops raise OutOfRangeError, but eager ops raise StopIteration
      with self.assertRaises(tf.errors.OutOfRangeError):
          tf.function(iterator_next_with_catching_stop_iteration)(
              self.ds, tf.constant(True)
          )
  
imports: import tensorflow
  from tensorflow.python.autograph.tests import reference_test_base
label_desc: Use image node_id 16 for calling the ReferenceTest obj's underlying member method code with example usage: obj.test_iterator_next_with_catching_stop_iteration() without return types