def check_level_names(df, index_names, column_names):
    """Assert that index and column level names are as expected"""
    if set(df.index.names) != set(index_names) or set(df.columns.names) != set(
        column_names):
        raise AssertionError(
            u'Expected dataframe with index ({}) and columns ({}), but found index ({}) and columns ({})'
            .format(index_names, column_names, df.index.names, df.columns.
            names))
    return None
