code: def test_output_match_dtype(self, padtype, dtype, xp, scp):
      # Test that the dtype of x is preserved per issue #14733
      x = xp.arange(10, dtype=dtype)
      y = scp.signal.resample_poly(x, 1, 2, padtype=padtype)
      return y
  
imports: import cupy
  from cupy import testing
  import cupyx.scipy.signal
  import cupyx.scipy.signal.windows
  import numpy
  import pytest
  from math import gcd
label_desc: Use image node_id 7 for calling the TestResample obj's underlying member method code with example usage: obj.test_output_match_dtype(padtype, dtype, xp, scp) and returns: y