code: def test_add_doc(self):
      # test that np.add_newdoc did attach a docstring successfully:
      tgt = "Current flat index into the array."
      assert_equal(np._core.flatiter.index.__doc__[: len(tgt)], tgt)
      assert_(len(np._core.ufunc.identity.__doc__) > 300)
      assert_(len(np.lib._index_tricks_impl.mgrid.__doc__) > 300)
  
imports: import sys
  import pytest
  import numpy
  from numpy import logspace, linspace, geomspace, dtype, array, arange, isnan, ndarray, sqrt, nextafter, stack, errstate
  from numpy._core import sctypes
  from numpy._core.function_base import add_newdoc
  from numpy.testing import assert_, assert_equal, assert_raises, assert_array_equal, assert_allclose, IS_PYPY
label_desc: Use image node_id 1 for calling the TestAdd_newdoc obj's underlying member method code with example usage: obj.test_add_doc() without return types