code: def test_intensity_or_color_as_rgba():
      assert _as_rgba(0.3) == Color((1.0, 1.0, 1.0, 0.3))
      assert _as_rgba((0.3, 0.2, 0.1)) == Color((0.3, 0.2, 0.1, 1.0))
      assert _as_rgba((0.3, 0.2, 0.1, 0.5)) == Color(
          (0.3, 0.2, 0.1, 0.5)
      )
  
file_path: vispy/vispy/visuals/tests/test_mesh.py
imports: import numpy
  from vispy import scene
  from vispy.color import Color
  from vispy.geometry import create_cube, create_sphere
  from vispy.testing import TestingCanvas, requires_application, run_tests_if_main, requires_pyopengl
  from vispy.visuals.filters import ShadingFilter, WireframeFilter
  from vispy.visuals.filters.mesh import _as_rgba
  import pytest
label_desc: Use image node_id 5 for calling a global function with example usage: test_intensity_or_color_as_rgba() without return types