@@ -293,9 +293,10 @@ def assert_equal(actual, desired, err_msg='', verbose=True, *, strict=False): |
293 | 293 |
|
294 | 294 | Notes |
295 | 295 | ----- |
296 | | - By default, when one of `actual` and `desired` is a scalar and the other is |
297 | | - an array, the function checks that each element of the array is equal to |
298 | | - the scalar. This behaviour can be disabled by setting ``strict==True``. |
| 296 | + When one of `actual` and `desired` is a scalar and the other is array_like, the |
| 297 | + function checks that each element of the array_like is equal to the scalar. |
| 298 | + Note that empty arrays are therefore considered equal to scalars. |
| 299 | + This behaviour can be disabled by setting ``strict==True``. |
299 | 300 |
|
300 | 301 | Examples |
301 | 302 | -------- |
@@ -980,9 +981,10 @@ def assert_array_equal(actual, desired, err_msg='', verbose=True, *, |
980 | 981 |
|
981 | 982 | Notes |
982 | 983 | ----- |
983 | | - When one of `actual` and `desired` is a scalar and the other is array_like, |
984 | | - the function checks that each element of the array_like object is equal to |
985 | | - the scalar. This behaviour can be disabled with the `strict` parameter. |
| 984 | + When one of `actual` and `desired` is a scalar and the other is array_like, the |
| 985 | + function checks that each element of the array_like is equal to the scalar. |
| 986 | + Note that empty arrays are therefore considered equal to scalars. |
| 987 | + This behaviour can be disabled by setting ``strict==True``. |
986 | 988 |
|
987 | 989 | Examples |
988 | 990 | -------- |
@@ -1651,10 +1653,10 @@ def assert_allclose(actual, desired, rtol=1e-7, atol=0, equal_nan=True, |
1651 | 1653 |
|
1652 | 1654 | Notes |
1653 | 1655 | ----- |
1654 | | - When one of `actual` and `desired` is a scalar and the other is |
1655 | | - array_like, the function performs the comparison as if the scalar were |
1656 | | - broadcasted to the shape of the array. |
1657 | | - This behaviour can be disabled with the `strict` parameter. |
| 1656 | + When one of `actual` and `desired` is a scalar and the other is array_like, the |
| 1657 | + function performs the comparison as if the scalar were broadcasted to the shape |
| 1658 | + of the array. Note that empty arrays are therefore considered equal to scalars. |
| 1659 | + This behaviour can be disabled by setting ``strict==True``. |
1658 | 1660 |
|
1659 | 1661 | Examples |
1660 | 1662 | -------- |
|