def assertFrameEqual(df1, df2, **kwds):
    """ Assert that two dataframes are equal, ignoring ordering of columns"""
from pandas.util.testing import assert_frame_equal
return assert_frame_equal(df1.sort(axis=1), df2.sort(axis=1), check_names=
    True, **kwds)
Equality in Pandas DataFrames - Column Order Matters?