Skip to content

Commit

Permalink
GH-36498: [Python][CI] Hypothesis nightly test fails with pytz.except…
Browse files Browse the repository at this point in the history
…ions.UnknownTimeZoneError: 'Factory' (#36508)

### What changes are included in this PR?

Skip the test if the timezone is `zoneinfo.ZoneInfo(key='Factory')`, because we don't support roundtripping such a timezone.

* Closes: #36498

Authored-by: AlenkaF <frim.alenka@gmail.com>
Signed-off-by: Joris Van den Bossche <jorisvandenbossche@gmail.com>
  • Loading branch information
AlenkaF authored Jul 7, 2023
1 parent 6a57a08 commit 375f3d9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/pyarrow/tests/test_pandas.py
Original file line number Diff line number Diff line change
Expand Up @@ -1070,7 +1070,7 @@ def test_python_datetime_with_pytz_tzinfo(self):
@h.given(st.none() | past.timezones)
@h.settings(deadline=None)
def test_python_datetime_with_pytz_timezone(self, tz):
if str(tz) == "build/etc/localtime":
if str(tz) in ["build/etc/localtime", "Factory"]:
pytest.skip("Localtime timezone not supported")
values = [datetime(2018, 1, 1, 12, 23, 45, tzinfo=tz)]
df = pd.DataFrame({'datetime': values})
Expand Down

0 comments on commit 375f3d9

Please sign in to comment.