code: def test_directly_connect_without_weights(
      nodes, edges, include_edge_id
  ):
      # Expect four lines starting at center (0.5, 0.5) and terminating
      # at a different corner and NaN
      data = pd.DataFrame(
          {
              "edge_id": [
                  1.0,
                  1.0,
                  np.nan,
                  2.0,
                  2.0,
                  np.nan,
                  3.0,
                  3.0,
                  np.nan,
                  4.0,
                  4.0,
                  np.nan,
              ],
              "x": [
                  0.0,
                  -100.0,
                  np.nan,
                  0.0,
                  100.0,
                  np.nan,
                  0.0,
                  -100.0,
                  np.nan,
                  0.0,
                  100.0,
                  np.nan,
              ],
              "y": [
                  0.0,
                  100.0,
                  np.nan,
                  0.0,
                  100.0,
                  np.nan,
                  0.0,
                  -100.0,
                  np.nan,
                  0.0,
                  -100.0,
                  np.nan,
              ],
          }
      )
      columns = ["edge_id", "x", "y"] if include_edge_id else ["x", "y"]
      expected = pd.DataFrame(data, columns=columns)
  
      given = directly_connect_edges(
          nodes, edges, include_edge_id=include_edge_id
      )
      assert given.equals(expected)
  
file_path: datashader/datashader/tests/test_bundling.py
imports: from __future__ import annotations
  import pytest
  import numpy
  import pandas
  from datashader.bundling import directly_connect_edges, hammer_bundle
  from datashader.layout import circular_layout, forceatlas2_layout, random_layout
label_desc: Use image node_id 8 for calling a global function with example usage: test_directly_connect_without_weights(nodes, edges, include_edge_id) without return types