@@ -47,16 +47,13 @@ def test_empty_scalar(self, xp, dtype, order):
47
47
a .fill (0 )
48
48
return a
49
49
50
- @pytest .mark .skip ("passing 'None' into shape arguments is not supported" )
51
- @testing .with_requires ("numpy>=1.20" )
50
+ @testing .with_requires ("numpy>=2.3" )
52
51
@testing .for_CF_orders ()
53
52
@testing .for_all_dtypes ()
54
- @testing .numpy_cupy_array_equal ()
55
- def test_empty_scalar_none (self , xp , dtype , order ):
56
- with testing .assert_warns (DeprecationWarning ):
57
- a = xp .empty (None , dtype = dtype , order = order )
58
- a .fill (0 )
59
- return a
53
+ def test_empty_scalar_none (self , dtype , order ):
54
+ for xp in (numpy , cupy ):
55
+ with pytest .raises (TypeError ):
56
+ xp .empty (None , dtype = dtype , order = order )
60
57
61
58
@testing .for_CF_orders ()
62
59
@testing .for_all_dtypes ()
@@ -206,14 +203,13 @@ def test_zeros(self, xp, dtype, order):
206
203
def test_zeros_scalar (self , xp , dtype , order ):
207
204
return xp .zeros ((), dtype = dtype , order = order )
208
205
209
- @pytest .mark .skip ("passing 'None' into shape arguments is not supported" )
210
- @testing .with_requires ("numpy>=1.20" )
206
+ @testing .with_requires ("numpy>=2.3" )
211
207
@testing .for_CF_orders ()
212
208
@testing .for_all_dtypes ()
213
- @ testing . numpy_cupy_array_equal ()
214
- def test_zeros_scalar_none ( self , xp , dtype , order ):
215
- with testing . assert_warns ( DeprecationWarning ):
216
- return xp .zeros (None , dtype = dtype , order = order )
209
+ def test_zeros_scalar_none ( self , dtype , order ):
210
+ for xp in ( numpy , cupy ):
211
+ with pytest . raises ( TypeError ):
212
+ xp .zeros (None , dtype = dtype , order = order )
217
213
218
214
@testing .for_CF_orders ()
219
215
@testing .for_all_dtypes ()
0 commit comments