code: def test_basic(self):
      a = mgrid[-1:1:10j]
      b = mgrid[-1:1:0.1]
      assert_(a.shape == (10,))
      assert_(b.shape == (20,))
      assert_(a[0] == -1)
      assert_almost_equal(a[-1], 1)
      assert_(b[0] == -1)
      assert_almost_equal(b[1] - b[0], 0.1, 11)
      assert_almost_equal(b[-1], b[0] + 19 * 0.1, 11)
      assert_almost_equal(a[1] - a[0], 2.0 / 9.0, 11)
  
imports: import pytest
  import numpy
  from numpy.testing import assert_, assert_equal, assert_array_equal, assert_almost_equal, assert_array_almost_equal, assert_raises, assert_raises_regex
  from numpy.lib.index_tricks import mgrid, ogrid, ndenumerate, fill_diagonal, diag_indices, diag_indices_from, index_exp, ndindex, r_, s_, ix_
label_desc: Use image node_id 1 for calling the TestGrid obj's underlying member method code with example usage: obj.test_basic() without return types