class_docstr: Unit tests for the
  :func:`~networkx.algorithms.matching.is_matching` function.
code: def test_invalid_input(self):
      error = nx.NetworkXError
      G = nx.path_graph(4)
      # edge to node not in G
      raises(error, nx.is_matching, G, {(0, 5), (2, 3)})
      # edge not a 2-tuple
      raises(error, nx.is_matching, G, {(0, 1, 2), (2, 3)})
      raises(error, nx.is_matching, G, {(0,), (2, 3)})
  
imports: import math
  from itertools import permutations
  from pytest import raises
  import networkx
  from networkx.algorithms.matching import matching_dict_to_set
  from networkx.utils import edges_equal
label_desc: Use image node_id 6 for calling the TestIsMatching obj's underlying member method code with example usage: obj.test_invalid_input() without return types