def METHOD_NAME(data_fixture):
    session_id = "1010"
    user = data_fixture.create_user(session_id=session_id)
    table = data_fixture.create_database_table(user=user)
    grid_view = data_fixture.create_grid_view(table=table)
    text_field = data_fixture.create_text_field(table=table)
    view_sort = data_fixture.create_view_sort(
        view=grid_view, field=text_field, order="ASC"
    )
    assert view_sort.view.id == grid_view.id
    assert view_sort.field.id == text_field.id
    assert view_sort.order == "ASC"
    action_type_registry.get_by_type(UpdateViewSortActionType).do(
        user, view_sort, order="DESC"
    )
    view_sort.refresh_from_db()
    assert view_sort.order == "DESC"
    ActionHandler.undo(user, [ViewActionScopeType.value(grid_view.id)], session_id)
    view_sort.refresh_from_db()
    assert view_sort.order == "ASC"