From b6c2e42967180b23ae354b55fd8fc491fbfe5051 Mon Sep 17 00:00:00 2001 From: Matthew Barber Date: Thu, 9 Sep 2021 17:29:26 +0100 Subject: [PATCH] Clarified comment in ellipsis indices test (NumPy and Array API) --- hypothesis-python/tests/array_api/test_indices.py | 3 ++- hypothesis-python/tests/numpy/test_gen_data.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hypothesis-python/tests/array_api/test_indices.py b/hypothesis-python/tests/array_api/test_indices.py index dc20ae003b..f3ab539443 100644 --- a/hypothesis-python/tests/array_api/test_indices.py +++ b/hypothesis-python/tests/array_api/test_indices.py @@ -66,7 +66,8 @@ def test_indices_can_generate_long_ellipsis(): ) ) def test_indices_replaces_whole_axis_slices_with_ellipsis(idx): - # If ... is in the slice, it replaces all ,:, entries for this shape. + # When a shape's dimension sizes are 0, ... in indices replaces all slice + # and integer entries in the index. assert slice(None) not in idx diff --git a/hypothesis-python/tests/numpy/test_gen_data.py b/hypothesis-python/tests/numpy/test_gen_data.py index 640562d189..ae84d1c16c 100644 --- a/hypothesis-python/tests/numpy/test_gen_data.py +++ b/hypothesis-python/tests/numpy/test_gen_data.py @@ -1106,7 +1106,8 @@ def test_basic_indices_can_generate_long_ellipsis(): ) ) def test_basic_indices_replaces_whole_axis_slices_with_ellipsis(idx): - # If ... is in the slice, it replaces all ,:, entries for this shape. + # When a shape's dimension sizes are 0, ... in indices replaces all slice + # and integer entries in the index. assert slice(None) not in idx