code: def test_core_number2(self):
      core = nx.core_number(self.H)
      nodes_by_core = [
          sorted(n for n in core if core[n] == val) for val in range(3)
      ]
      assert nodes_equal(nodes_by_core[0], [0])
      assert nodes_equal(nodes_by_core[1], [1, 3])
      assert nodes_equal(nodes_by_core[2], [2, 4, 5, 6])
  
imports: import pytest
  import networkx
  from networkx.utils import nodes_equal
label_desc: Use image node_id 4 for calling the TestCore obj's underlying member method code with example usage: obj.test_core_number2() without return types