code: def test_set_undersized_data(self):
      data = np.zeros((10, 10), dtype=np.uint8)
      T = Texture2D(data=data)
      T.set_data(np.ones((5, 5), np.uint8))
      assert T.shape == (5, 5, 1)
      glir_cmds = T._glir.clear()
      assert glir_cmds[-2][0] == "SIZE"
      assert glir_cmds[-1][0] == "DATA"
  
imports: import unittest
  import numpy
  import pytest
  from vispy.gloo import Texture1D, Texture2D, Texture3D, TextureAtlas
  from vispy.testing import requires_pyopengl, run_tests_if_main, assert_raises
label_desc: Use image node_id 7 for calling the Texture2DTest obj's underlying member method code with example usage: obj.test_set_undersized_data() without return types