def METHOD_NAME(
    restart_dir, include_agrid_winds, coarsen_agrid_winds, dropped_fv_core_variables
):
    grid_spec_path = str(restart_dir.join("grid_spec"))
    src_path = str(restart_dir)
    in_res = "48"
    out_res = "6"
    time = "20160101.000000"
    dest = str(restart_dir.join("output"))
    args = [src_path, grid_spec_path, in_res, out_res, dest]
    if coarsen_agrid_winds:
        args.append("--coarsen-agrid-winds")
    if coarsen_agrid_winds and not include_agrid_winds:
        with pytest.raises(ValueError, match="'ua' and 'va'"):
            main(args)
    else:
        main(args)
        for destination_category, source_category in OUTPUT_CATEGORY_NAMES.items():
            if "fv_core" in destination_category:
                assert_expected_variables_were_coarsened(
                    source_category,
                    destination_category,
                    time,
                    src_path,
                    dest,
                    dropped_fv_core_variables,
                )
            else:
                assert_expected_variables_were_coarsened(
                    source_category, destination_category, time, src_path, dest
                )