apache / apache/arrow

[Python] test_assume_timezone does not assert nonexistent and ambiguous results

Open
#50,530 0 comments 0 reactions 1 assignee Claimed by @anxkhn View on GitHub
Component: Python
Dominant language
C++
Stars
17.1k
Forks
4.3k
Avg merge
3d 13h
Merged PRs (30d)
88

Description

### Describe the bug, including details regarding any error messages, version, and platform.

`test_assume_timezone` in `python/pyarrow/tests/test_compute.py` performs four `.equals()` comparisons without asserting their boolean results. The comparisons for nonexistent times (`shift_forward` and `shift_backward`) and ambiguous times (earliest and latest) are therefore discarded, allowing incorrect kernel output on those branches to pass the test.

Expected: each computed result is asserted against the expected timestamp array.

Actual: the four comparisons execute but verify nothing.

### Component(s)

Python

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.