Skip to content

Commit 80dcec6

Browse files
committed
replace another dict with OrderedDict
1 parent e11b2ab commit 80dcec6

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pandas/tests/io/test_stata.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
import warnings
99
from datetime import datetime
1010
from distutils.version import LooseVersion
11+
from collections import OrderedDict
1112

1213
import numpy as np
1314
import pandas as pd
@@ -945,7 +946,7 @@ def test_categorical_order(self, file):
945946
cols.append((col, pd.Categorical.from_codes(codes, labels)))
946947
else:
947948
cols.append((col, pd.Series(labels, dtype=np.float32)))
948-
expected = DataFrame(dict(cols), columns=dict(cols).keys())
949+
expected = DataFrame(dict(cols), columns=OrderedDict(cols).keys())
949950

950951
# Read with and with out categoricals, ensure order is identical
951952
file = getattr(self, file)

0 commit comments

Comments
 (0)