code: def test_digraph_rejected():
      df = cudf.DataFrame()
      df["src"] = cudf.Series(range(10))
      df["dst"] = cudf.Series(range(10))
      df["val"] = cudf.Series(range(10))
  
      G = cugraph.Graph(directed=True)
      G.from_cudf_edgelist(
          df,
          source="src",
          destination="dst",
          edge_attr="val",
          renumber=False,
      )
  
      with pytest.raises(ValueError):
          cugraph_call(G, 2)
  
file_path: cugraph/python/cugraph/cugraph/tests/community/test_modularity.py
imports: import gc
  import random
  import pytest
  import networkx
  import cudf
  import cugraph
  from cugraph.testing import utils, DEFAULT_DATASETS
  from cugraph.utilities import ensure_cugraph_obj_for_nx
label_desc: Use image node_id 6 for calling a global function with example usage: test_digraph_rejected() without return types