code: def test_unknown_algorithm():
      with pytest.raises(ValueError):
          nx.minimum_spanning_tree(nx.Graph(), algorithm="random")
      with pytest.raises(
          ValueError,
          match="random is not a valid choice for an algorithm.",
      ):
          nx.maximum_spanning_edges(nx.Graph(), algorithm="random")
  
imports: import pytest
  import networkx
  from networkx.utils import edges_equal, nodes_equal
label_desc: Use image node_id 1 for calling a global function with example usage: test_unknown_algorithm() without return types