Skip to content

Commit f076795

Browse files
test: Add test for 0
1 parent 370d827 commit f076795

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

tests/test_dataframe_compatibility.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ def test_LO_init_missingGetValueError_lengthFunc() -> None:
7777
)
7878

7979

80-
def test_LO_init_invalidLengthValueError() -> None:
80+
def test_LO_init_invalidLengthValueError_negative() -> None:
8181
with pytest.raises(ValueError):
8282
ParallelProcessing(
8383
function=lambda x: x,
@@ -86,6 +86,15 @@ def test_LO_init_invalidLengthValueError() -> None:
8686
)
8787

8888

89+
def test_LO_init_invalidLengthValueError_zero() -> None:
90+
with pytest.raises(AssertionError):
91+
ParallelProcessing(
92+
function=lambda x: x,
93+
dataset=DummyLengthOnly(0),
94+
_get_value=lambda *_: _,
95+
)
96+
97+
8998
def test_LO_init_nonIntLengthError_numLike() -> None:
9099
with pytest.raises(TypeError):
91100
ParallelProcessing(

0 commit comments

Comments
 (0)