class_docstr: Test that the Fourier coefficients of a single-variable function are computed correctly
class_docstr_tok: ["Test","that","the","Fourier","coefficients","of","a","single-variable","function","are","computed","correctly"]
docstr: Test that the Fourier coefficients of a single-variable
  function are computed correctly
docstr_tok: ["Test","that","the","Fourier","coefficients","of","a","single-variable","function","are","computed","correctly"]
code: def test_single_variable_fourier_coeffs(
      self, freq_dict, expected_coeffs
  ):
      """Test that the Fourier coefficients of a single-variable
      function are computed correctly"""
      degree = max(freq_dict.keys())
      partial_func = partial(fourier_function, freq_dict)
      # Testing with a single degree provided as integer
      coeffs = coefficients(partial_func, 1, degree)
  
      assert np.allclose(coeffs, expected_coeffs)
      # Testing with a single-entry sequence of degrees
      coeffs = coefficients(partial_func, 1, (degree,))
  
      assert np.allclose(coeffs, expected_coeffs)
  
imports: from functools import partial
  import pytest
  import pennylane
  from pennylane import numpy
  from pennylane.fourier import coefficients
label_desc: Use image node_id 1 for calling the TestFourierCoefficientSingleVariable obj's underlying member method code with example usage: obj.test_single_variable_fourier_coeffs(freq_dict, expected_coeffs) without return types