Skip to content

Commit

Permalink
GH-39999: [Python] Fix tests for pandas with CoW / nightly integratio…
Browse files Browse the repository at this point in the history
…n tests (#40000)

### Rationale for this change

Fixing a failing test with pandas nightly because of CoW changes.

* Closes: #39999

Authored-by: Joris Van den Bossche <jorisvandenbossche@gmail.com>
Signed-off-by: Joris Van den Bossche <jorisvandenbossche@gmail.com>
  • Loading branch information
jorisvandenbossche authored Feb 9, 2024
1 parent a0dec7f commit 40cb0a2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/pyarrow/tests/test_pandas.py
Original file line number Diff line number Diff line change
Expand Up @@ -3650,7 +3650,8 @@ def test_singleton_blocks_zero_copy():

prior_allocation = pa.total_allocated_bytes()
result = t.to_pandas()
assert result['f0'].values.flags.writeable
# access private `_values` because the public `values` is made read-only by pandas
assert result['f0']._values.flags.writeable
assert pa.total_allocated_bytes() > prior_allocation


Expand Down

0 comments on commit 40cb0a2

Please sign in to comment.