class_docstr: Test that get_measurement_function dispatchs to the correct place.
docstr: Check that the sparse expectation value method is used if the state is numpy and
  the Sum is large with overlapping wires.
docstr_tok: ["Check","that","the","sparse","expectation","value","method","is","used","if","the","state","is","numpy","and","the","Sum","is","large","with","overlapping","wires","."]
code: def test_sum_sparse_method_when_large_and_nonoverlapping(self):
      """Check that the sparse expectation value method is used if the state is numpy and
      the Sum is large with overlapping wires."""
      S = qml.prod(*(qml.PauliX(i) for i in range(8))) + qml.prod(
          *(qml.PauliY(i) for i in range(8))
      )
      state = np.zeros(2)
      assert (
          get_measurement_function(qml.expval(S), state)
          is csr_dot_products
      )
  
imports: import pytest
  import numpy
  from scipy.sparse import csr_matrix
  import pennylane
  from pennylane.devices.qubit import simulate
  from pennylane.devices.qubit.measure import measure, state_diagonalizing_gates, csr_dot_products, full_dot_products, get_measurement_function, sum_of_terms_method
label_desc: Use image node_id 6 for calling the TestMeasurementDispatch obj's underlying member method code with example usage: obj.test_sum_sparse_method_when_large_and_nonoverlapping() without return types