code: def test_r_colorscales():
      for colorscale_members in [
          inspect.getmembers(px.colors.sequential),
          inspect.getmembers(px.colors.diverging),
          inspect.getmembers(px.colors.cyclical),
          inspect.getmembers(px.colors.qualitative),
          inspect.getmembers(px.colors.carto),
          inspect.getmembers(px.colors.cmocean),
          inspect.getmembers(px.colors.colorbrewer),
          inspect.getmembers(px.colors.plotlyjs),
      ]:
          scale_names = [
              c[0]
              for c in colorscale_members
              if isinstance(c, tuple)
              and len(c) == 2
              and isinstance(c[0], str)
              and isinstance(c[1], list)
              and not c[0].startswith("_")
          ]
          for scale in scale_names:
              if scale.endswith("_r"):
                  assert scale.replace("_r", "") in scale_names
              else:
                  assert scale + "_r" in scale_names
  
imports: import plotly.express
  import inspect
label_desc: Use image node_id 2 for calling a global function with example usage: test_r_colorscales() without return types