class documentation
class TestFutureWarningArrayLikeNotIterable(_DeprecationTestCase): (source)
Undocumented
Method | test |
Undocumented |
Method | test |
Undocumented |
Method | test |
Test that these objects give a warning since they are not 0-D, not coerced at the top level np.array(obj) , but nested, and do not define the sequence protocol. |
Method | test |
The old code would actually use the dtype from the array, but then end up not using the array (for dimension discovery) |
Method | test |
Undocumented |
Class Variable | message |
Undocumented |
Inherited from _DeprecationTestCase
:
Method | assert |
Test if DeprecationWarnings are given and raised. |
Method | assert |
Test that warnings are not raised. |
Method | setup |
Undocumented |
Method | teardown |
Undocumented |
Instance Variable | log |
Undocumented |
Instance Variable | warn |
Undocumented |
@pytest.mark.parametrize( 'protocol', [ '__array__', '__array_interface__', '__array_struct__'])
def test_0d_not_deprecated(self, protocol): (source) ¶
def test_0d_not_deprecated(self, protocol): (source) ¶
Undocumented
@pytest.mark.parametrize( 'protocol', [ '__array__', '__array_interface__', '__array_struct__'])
def test_assignment_not_deprecated(self, protocol): (source) ¶
def test_assignment_not_deprecated(self, protocol): (source) ¶
Undocumented
@pytest.mark.parametrize( 'protocol', [ '__array__', '__array_interface__', '__array_struct__'])
def test_deprecated(self, protocol): (source) ¶
def test_deprecated(self, protocol): (source) ¶
Test that these objects give a warning since they are not 0-D,
not coerced at the top level np.array(obj)
, but nested, and do
not define the sequence protocol.
- NOTE: Tests for the versions including __len__ and __getitem__ exist
- in
test_array_coercion.py
and they can be modified or amended when this deprecation expired.
@pytest.mark.parametrize( 'protocol', [ '__array__', '__array_interface__', '__array_struct__'])
def test_strange_dtype_handling(self, protocol): (source) ¶
def test_strange_dtype_handling(self, protocol): (source) ¶
The old code would actually use the dtype from the array, but then end up not using the array (for dimension discovery)
@pytest.mark.parametrize( 'protocol', [ '__array__', '__array_interface__', '__array_struct__'])
def test_unnested_not_deprecated(self, protocol): (source) ¶
def test_unnested_not_deprecated(self, protocol): (source) ¶
Undocumented