Skip to content

Commit 9999d96

Browse files
committed
Fix dtypes type hints in elwise+op tests
1 parent 42b240b commit 9999d96

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

array_api_tests/test_operators_and_elementwise_functions.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import math
22
import operator
33
from enum import Enum, auto
4-
from typing import Callable, List, NamedTuple, Optional, TypeVar, Union
4+
from typing import Callable, List, NamedTuple, Optional, Sequence, TypeVar, Union
55

66
import pytest
77
from hypothesis import assume, given
@@ -37,7 +37,7 @@ class OnewayPromotableDtypes(NamedTuple):
3737

3838
@st.composite
3939
def oneway_promotable_dtypes(
40-
draw, dtypes: List[DataType]
40+
draw, dtypes: Sequence[DataType]
4141
) -> st.SearchStrategy[OnewayPromotableDtypes]:
4242
"""Return a strategy for input dtypes that promote to result dtypes."""
4343
d1, d2 = draw(hh.mutually_promotable_dtypes(dtypes=dtypes))
@@ -346,7 +346,7 @@ def __repr__(self):
346346

347347

348348
def make_binary_params(
349-
elwise_func_name: str, dtypes: List[DataType]
349+
elwise_func_name: str, dtypes: Sequence[DataType]
350350
) -> List[Param[BinaryParamContext]]:
351351
if hh.FILTER_UNDEFINED_DTYPES:
352352
dtypes = [d for d in dtypes if not isinstance(d, xp._UndefinedStub)]

0 commit comments

Comments
 (0)