class_docstr: Unit tests for writing graphs in the sparse6 format.
  
  Most of the test cases were checked against the sparse6 encoder in Sage.
class_docstr_tok: ["Unit","tests","for","writing","graphs","in","the","sparse6","format",".","Most","of","the","test","cases","were","checked","against","the","sparse6","encoder","in","Sage","."]
code: def test_complete_graph(self):
      G = nx.complete_graph(4)
      result = BytesIO()
      nx.write_sparse6(G, result)
      assert result.getvalue() == b">>sparse6<<:CcKI\n"
  
imports: from io import BytesIO
  import pytest
  import networkx
  from networkx.utils import edges_equal, nodes_equal
label_desc: Use image node_id 6 for calling the TestWriteSparse6 obj's underlying member method code with example usage: obj.test_complete_graph() without return types