code: def test_spiral_layout(self):
      G = self.Gs
  
      # a lower value of resolution should result in a more compact layout
      # intuitively, the total distance from the start and end nodes
      # via each node in between (transiting through each) will be less,
      # assuming rescaling does not occur on the computed node positions
      pos_standard = np.array(
          list(nx.spiral_layout(G, resolution=0.35).values())
      )
      pos_tighter = np.array(
          list(nx.spiral_layout(G, resolution=0.34).values())
      )
      distances = np.linalg.norm(
          pos_standard[:-1] - pos_standard[1:], axis=1
      )
      distances_tighter = np.linalg.norm(
          pos_tighter[:-1] - pos_tighter[1:], axis=1
      )
      assert sum(distances) > sum(distances_tighter)
  
      # return near-equidistant points after the first value if set to true
      pos_equidistant = np.array(
          list(nx.spiral_layout(G, equidistant=True).values())
      )
      distances_equidistant = np.linalg.norm(
          pos_equidistant[:-1] - pos_equidistant[1:], axis=1
      )
      assert np.allclose(
          distances_equidistant[1:],
          distances_equidistant[-1],
          atol=0.01,
      )
  
imports: import pytest
  import networkx
label_desc: Use image node_id 27 for calling the TestLayout obj's underlying member method code with example usage: obj.test_spiral_layout() without return types