()
| 257 | |
| 258 | |
| 259 | def test_schema_weakref(): |
| 260 | fields = [ |
| 261 | pa.field('foo', pa.int32()), |
| 262 | pa.field('bar', pa.string()), |
| 263 | pa.field('baz', pa.list_(pa.int8())) |
| 264 | ] |
| 265 | schema = pa.schema(fields) |
| 266 | wr = weakref.ref(schema) |
| 267 | assert wr() is not None |
| 268 | del schema |
| 269 | assert wr() is None |
| 270 | |
| 271 | |
| 272 | def test_schema_to_string_with_metadata(): |