(version)
| 235 | |
| 236 | @pytest.mark.pandas |
| 237 | def test_float_nulls(version): |
| 238 | num_values = 100 |
| 239 | |
| 240 | path = random_path() |
| 241 | TEST_FILES.append(path) |
| 242 | |
| 243 | null_mask = np.random.randint(0, 10, size=num_values) < 3 |
| 244 | dtypes = ['f4', 'f8'] |
| 245 | expected_cols = [] |
| 246 | |
| 247 | arrays = [] |
| 248 | for name in dtypes: |
| 249 | values = np.random.randn(num_values).astype(name) |
| 250 | arrays.append(pa.array(values, mask=null_mask)) |
| 251 | |
| 252 | values[null_mask] = np.nan |
| 253 | |
| 254 | expected_cols.append(values) |
| 255 | |
| 256 | table = pa.table(arrays, names=dtypes) |
| 257 | _check_arrow_roundtrip(table) |
| 258 | |
| 259 | df = table.to_pandas() |
| 260 | _check_pandas_roundtrip(df, version=version) |
| 261 | |
| 262 | |
| 263 | @pytest.mark.pandas |
nothing calls this directly
no test coverage detected