fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel module

tests for the underlying python module behind fre app mask-atmos-plevel functionality

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel(tmp_input, tmp_ps, tmp_ref, tmp_path)

Do the pressure masking on the test input file, and then compare to a previously generated output file.

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_case2(tmp_case2input, tmp_ps, tmp_case2ref, tmp_path)

Do the pressure masking on the test input file without pressure_mask attribute, but _unmsk in var name and then compare to a previously generated output file.

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_exception()

if the input file doesn’t exist, error

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_no_missing_val(tmp_input, tmp_ps, tmp_path)

Do the pressure masking on the test input file, and then compare to a previously generated output file.

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_no_ps_error(tmp_input, tmp_path)

if the input and ps files exist, but the ps file does not have ps within it, raise ValueError using the input file itself as the ps file is OK, it just has to NOT have ps

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_no_ps_file_noop(tmp_input, tmp_ps, tmp_path)

if the input file exists, but the ps file does not, then no-op gracefully without raising an exception or throwing an error

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_no_ps_warn(tmp_input, tmp_path)

if the input file exists, but the ps file does not, then no-op gracefully without raising an exception or throwing an error while warn_no_ps = True using the input file itself as the ps file is OK, it just has to NOT have ps

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_pressure_mask_true(tmp_input, tmp_ps, tmp_path)

Do the pressure masking on the test input file, and then compare to a previously generated output file.

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_mask_atmos_plevel_recreate_output(tmp_input, tmp_ps, tmp_ref, tmp_path)

Do the pressure masking on the test input file, remaking an existing output file and then compare to a previously generated output file.

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_pressure_coordinate_continue_warning(tmp_input)

tests a clean no-op when the dimension is not stored as a variable/coordinate of the desired data to be masked

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.test_pressure_coordinate_found_no_long_name(tmp_input)

tests that a pressure coordinate can still be found under certain conditions when the long_name attribute isn’t as expected

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.tmp_case2input(tmp_path)

write netcdf files from cdl, data (ua_unmsk) no pressure_mask attr

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.tmp_case2ref(tmp_path)

write netcdf files from cdl, data (ua) for checking answers when there is no pressure_mask attr

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.tmp_input(tmp_path)

write netcdf files from cdl, data (ua_unmsk)

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.tmp_ps(tmp_path)

write netcdf files from cdl, data (ps)

fre.app.mask_atmos_plevel.tests.test_mask_atmos_plevel.tmp_ref(tmp_path)

write netcdf files from cdl, data (ua) for checking answers