We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bf99975 commit ee93b34Copy full SHA for ee93b34
pandas/tests/io/test_pytables.py
@@ -5191,6 +5191,16 @@ def test_query_compare_column_type(self):
5191
expected = df.loc[[], :]
5192
tm.assert_frame_equal(expected, result)
5193
5194
+ def test_read_hdf_series_fixed(self):
5195
+ # GH 16583
5196
+ # Tests that reading a Series saved to an HDF file in 'fixed' format
5197
+ # still works if a mode='r' argument is supplied
5198
+ series = tm.makeFloatSeries()
5199
+ with ensure_clean_path(self.path) as path:
5200
+ series.to_hdf(path, key='data', format='fixed')
5201
+ result = pd.read_hdf(path, key='data', mode='r')
5202
+ tm.assert_series_equal(result, series)
5203
+
5204
@pytest.mark.skipif(sys.version_info < (3, 6), reason="Need python 3.6")
5205
def test_fspath(self):
5206
with tm.ensure_clean('foo.h5') as path:
0 commit comments