code: def test_three_nodes_multigraph(self, method):
      pytest.importorskip("scipy")
      G = nx.MultiDiGraph()
      G.add_weighted_edges_from(
          [(1, 2, 1), (1, 3, 2), (2, 3, 1), (2, 3, 2)]
      )
      order = nx.spectral_ordering(G, method=method)
      assert set(order) == set(G)
      assert {2, 3} in (set(order[:-1]), set(order[1:]))
  
imports: from math import sqrt
  import pytest
  import networkx
label_desc: Use image node_id 5 for calling the TestSpectralOrdering obj's underlying member method code with example usage: obj.test_three_nodes_multigraph(method) without return types