code: def test_random():
      # Just test that these triangulate without exception.
      # TODO: later on, we can turn this same test into an image comparison
      # with Polygon.
      N = 10
      np.random.seed(0)
  
      for i in range(4):
          pts = np.random.normal(size=(N, 2))
          edges = np.zeros((N, 2), dtype=int)
          edges[:, 0] = np.arange(N)
          edges[:, 1] = np.arange(1, N + 1) % N
  
          t = T(pts, edges)
          t.triangulate()
  
      theta = np.linspace(0, 2 * np.pi, 11)[:-1]
      pts = np.hstack(
          [np.cos(theta)[:, np.newaxis], np.sin(theta)[:, np.newaxis]]
      )
      pts[::2] *= 0.4
      edges = np.empty((pts.shape[0], 2), dtype=np.uint)
      edges[:, 0] = np.arange(pts.shape[0])
      edges[:, 1] = edges[:, 0] + 1
      edges[-1, 1] = 0
      t = T(pts, edges)
      t.triangulate()
  
file_path: vispy/vispy/geometry/tests/test_triangulation.py
imports: import sys
  from unittest import SkipTest
  import numpy
  from numpy.testing import assert_array_almost_equal
  from vispy.testing import run_tests_if_main
  from vispy.geometry.triangulation import Triangulation
label_desc: Use image node_id 8 for calling a global function with example usage: test_random() without return types