(pickle_module)
| 2471 | |
| 2472 | |
| 2473 | def test_array_pickle_dictionary(pickle_module): |
| 2474 | # not included in the above as dictionary array cannot be created with |
| 2475 | # the pa.array function |
| 2476 | array = pa.DictionaryArray.from_arrays([0, 1, 2, 0, 1], ['a', 'b', 'c']) |
| 2477 | for proto in range(0, pickle_module.HIGHEST_PROTOCOL + 1): |
| 2478 | result = pickle_module.loads(pickle_module.dumps(array, proto)) |
| 2479 | assert array.equals(result) |
| 2480 | |
| 2481 | |
| 2482 | @pytest.mark.numpy |