code: def test_invalid_view_after_resize(self):
      dtype = np.dtype(
          [
              ("position", np.float32, 3),
              ("texcoord", np.float32, 2),
              ("color", np.float32, 4),
          ]
      )
      data = np.zeros(10, dtype=dtype)
      B = DataBuffer(data)
      Y = B["position"]
      Z = B[5:]
      B.resize_bytes(5)
      assert Y._valid is False
      assert Z._valid is False
  
imports: import unittest
  import numpy
  from vispy.testing import run_tests_if_main
  from vispy.gloo.buffer import Buffer, DataBuffer, DataBufferView, VertexBuffer, IndexBuffer
label_desc: Use image node_id 7 for calling the DataBufferTest obj's underlying member method code with example usage: obj.test_invalid_view_after_resize() without return types