code: def test_module_add_edge(idtype):
      transform = dgl.AddEdge()
      g = dgl.heterograph(
          {
              ("A", "r1", "B"): ([0, 1, 2, 3, 4], [1, 2, 3, 4, 5]),
              ("C", "r2", "C"): ([0, 1, 2, 3, 4], [1, 2, 3, 4, 5]),
          },
          idtype=idtype,
          device=F.ctx(),
      )
      num_edges_old = g.num_edges()
      new_g = transform(g)
      assert new_g.num_edges(("A", "r1", "B")) == 6
      assert new_g.num_edges(("C", "r2", "C")) == 6
      assert new_g.idtype == g.idtype
      assert new_g.device == g.device
      assert new_g.ntypes == g.ntypes
      assert new_g.canonical_etypes == g.canonical_etypes
      num_edges_new = g.num_edges()
      # Ensure that the original graph is not corrupted
      assert num_edges_old == num_edges_new
  
imports: import math
  import os
  import unittest
  import backend
  import dgl
  import dgl.function
  import dgl.partition
  import networkx
  import numpy
  import pytest
  from scipy import sparse
  from utils import parametrize_idtype
  from utils.graph_cases import get_cases
label_desc: Use image node_id 48 for calling a global function with example usage: test_module_add_edge(idtype) without return types