@@ -25,6 +25,7 @@ def test_variable_numerical_reduce(self, op, data):
25
25
# compute using xp.<OP>(array)
26
26
expected = getattr (self .xp , op )(variable .data )
27
27
28
+ assert isinstance (actual , self .array_type ), f"wrong type: { type (actual )} "
28
29
self .assert_equal (actual , expected )
29
30
30
31
@pytest .mark .parametrize ("op" , ["all" , "any" ])
@@ -38,7 +39,7 @@ def test_variable_boolean_reduce(self, op, data):
38
39
# compute using xp.<OP>(array)
39
40
expected = getattr (self .xp , op )(variable .data )
40
41
41
- assert isinstance (actual , self .array_type )
42
+ assert isinstance (actual , self .array_type ), f"wrong type: { type ( actual ) } "
42
43
self .assert_equal (actual , expected )
43
44
44
45
@pytest .mark .parametrize ("op" , ["max" , "min" ])
@@ -52,7 +53,7 @@ def test_variable_order_reduce(self, op, data):
52
53
# compute using xp.<OP>(array)
53
54
expected = getattr (self .xp , op )(variable .data )
54
55
55
- assert isinstance (actual , self .array_type )
56
+ assert isinstance (actual , self .array_type ), f"wrong type: { type ( actual ) } "
56
57
self .assert_equal (actual , expected )
57
58
58
59
@pytest .mark .parametrize ("op" , ["argmax" , "argmin" ])
@@ -95,5 +96,5 @@ def test_variable_cumulative_reduce(self, op, data):
95
96
for axis in range (variable .ndim ):
96
97
expected = getattr (self .xp , array_api_names [op ])(expected , axis = axis )
97
98
98
- assert isinstance (actual , self .array_type )
99
+ assert isinstance (actual , self .array_type ), f"wrong type: { type ( actual ) } "
99
100
self .assert_equal (actual , expected )
0 commit comments