From 3064b06a91b465d72311fa62f8a5c573ec743e09 Mon Sep 17 00:00:00 2001 From: alimcmaster1 Date: Sat, 20 Jun 2020 10:34:52 +0100 Subject: [PATCH 1/2] Feather Column Ordering --- pandas/tests/io/test_feather.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pandas/tests/io/test_feather.py b/pandas/tests/io/test_feather.py index e59100146249a..7e3debae8a3e2 100644 --- a/pandas/tests/io/test_feather.py +++ b/pandas/tests/io/test_feather.py @@ -115,6 +115,11 @@ def test_read_columns(self): columns = ["col1", "col3"] self.check_round_trip(df, expected=df[columns], columns=columns) + def read_columns_different_order(self): + # GH 33878 + df = pd.DataFrame({"A": [1, 2], "B": ["x", "y"], "C": [True, False]}) + self.check_round_trip(df, columns=["B", "A"]) + def test_unsupported_other(self): # mixed python objects From 7e71d06a064025181ae5d9776ce1cf6e9db2d6f9 Mon Sep 17 00:00:00 2001 From: alimcmaster1 Date: Sat, 20 Jun 2020 10:43:17 +0100 Subject: [PATCH 2/2] Arrow skip --- pandas/tests/io/test_feather.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pandas/tests/io/test_feather.py b/pandas/tests/io/test_feather.py index 7e3debae8a3e2..a8a5c8f00e6bf 100644 --- a/pandas/tests/io/test_feather.py +++ b/pandas/tests/io/test_feather.py @@ -115,6 +115,7 @@ def test_read_columns(self): columns = ["col1", "col3"] self.check_round_trip(df, expected=df[columns], columns=columns) + @td.skip_if_no("pyarrow", min_version="0.17.1") def read_columns_different_order(self): # GH 33878 df = pd.DataFrame({"A": [1, 2], "B": ["x", "y"], "C": [True, False]})