TST: test gamma with complex-valued inputs
@@ -17,12 +17,14 @@ class TestGamma(unittest.TestCase):
a = testing.shaped_arange((2, 3), xp, dtype)
return scp.special.gamma(a)
- @testing.for_all_dtypes(no_complex=True, no_bool=True)
+ @testing.for_all_dtypes(no_bool=True)
@testing.numpy_cupy_allclose(atol=1e-5, rtol=1e-5, scipy_name='scp')
def test_linspace(self, xp, scp, dtype):
import scipy.special # NOQA
a = numpy.linspace(-30, 30, 1000, dtype=dtype)
+ if a.dtype.kind == 'c':
+ a -= 1j * a
a = xp.asarray(a)
return scp.special.gamma(a)
