code: def test_is_weakly_connected(self):
      for G, C in self.gc:
          U = G.to_undirected()
          assert nx.is_weakly_connected(G) == nx.is_connected(U)
  
file_path: networkx/networkx/algorithms/components/tests/test_weakly_connected.py
imports: import pytest
  import networkx
  from networkx import NetworkXNotImplemented
label_desc: Use image node_id 4 for calling the TestWeaklyConnected obj's underlying member method code with example usage: obj.test_is_weakly_connected() without return types