Skip to content

Commit

Permalink
re-add online markers
Browse files Browse the repository at this point in the history
  • Loading branch information
Zeitsperre committed Oct 23, 2024
1 parent c4268a6 commit 16e4f44
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 42 deletions.
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ addopts = [
]
python_files = ["test_*.py"]
markers = [
"online: mark test to need internet connection",
"smoke: mark test as a smoke/sanity test"
]

Expand Down
42 changes: 0 additions & 42 deletions tests/smoke/test_smoke_checks.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,6 @@
)


@pytest.mark.smoke
def test_smoke_get_capabilities(wps):
caps = wps.getcapabilities()
assert caps.identification.type == "WPS"
Expand All @@ -221,7 +220,6 @@ def test_smoke_get_capabilities(wps):
assert "orchestrate" in processes


@pytest.mark.smoke
def test_smoke_describe_process_subset(wps):
process = wps.describeprocess("subset")
assert process.identifier == "subset"
Expand All @@ -231,7 +229,6 @@ def test_smoke_describe_process_subset(wps):
assert "area" in inputs


@pytest.mark.smoke
def test_smoke_describe_process_average_dim(wps):
process = wps.describeprocess("average")
assert process.identifier == "average"
Expand All @@ -240,7 +237,6 @@ def test_smoke_describe_process_average_dim(wps):
assert "dims" in inputs


@pytest.mark.smoke
def test_smoke_describe_process_average_time(wps):
process = wps.describeprocess("average_time")
assert process.identifier == "average_time"
Expand All @@ -249,15 +245,13 @@ def test_smoke_describe_process_average_time(wps):
assert "freq" in inputs


@pytest.mark.smoke
def test_smoke_describe_process_orchestrate(wps):
process = wps.describeprocess("orchestrate")
assert process.identifier == "orchestrate"
inputs = [inpt.identifier for inpt in process.dataInputs]
assert "workflow" in inputs


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip5_subset(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CMIP5_DAY_COLLECTION),
Expand All @@ -270,7 +264,6 @@ def test_smoke_execute_c3s_cmip5_subset(wps, tmp_path, open_dataset):
assert "tas" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CMIP6_MON_COLLECTION),
Expand All @@ -283,7 +276,6 @@ def test_smoke_execute_c3s_cmip6_subset(wps, tmp_path, open_dataset):
assert "rlds" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset_level(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CMIP6_MON_LEVEL_COLLECTION),
Expand All @@ -297,7 +289,6 @@ def test_smoke_execute_c3s_cmip6_subset_level(wps, tmp_path, open_dataset):
assert "ta" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset_metadata(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CMIP6_MON_TASMIN_COLLECTION),
Expand Down Expand Up @@ -326,7 +317,6 @@ def test_smoke_execute_c3s_cmip6_subset_metadata(wps, tmp_path, open_dataset):
assert "coordinates" not in ds.time_bnds.encoding


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset_area_fill_value(wps, tmp_path, open_dataset):
dsid = "c3s-cmip6.CMIP.NCAR.CESM2-WACCM.historical.r1i1p1f1.day.tas.gn.v20190227"
inputs = [
Expand All @@ -341,7 +331,6 @@ def test_smoke_execute_c3s_cmip6_subset_area_fill_value(wps, tmp_path, open_data
assert "tas" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cordex_subset(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CORDEX_MON_COLLECTION),
Expand All @@ -357,7 +346,6 @@ def test_smoke_execute_c3s_cordex_subset(wps, tmp_path, open_dataset):
assert "tas" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip5_subset_by_point(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CMIP5_DAY_COLLECTION),
Expand All @@ -371,7 +359,6 @@ def test_smoke_execute_c3s_cmip5_subset_by_point(wps, tmp_path, open_dataset):
assert "tas" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset_by_point(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CMIP6_MON_COLLECTION),
Expand All @@ -385,7 +372,6 @@ def test_smoke_execute_c3s_cmip6_subset_by_point(wps, tmp_path, open_dataset):
assert "rlds" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_360calendar_subset_by_point(
wps, tmp_path, open_dataset
):
Expand All @@ -401,7 +387,6 @@ def test_smoke_execute_c3s_cmip6_360calendar_subset_by_point(
assert "pr" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cordex_subset_by_point(wps, tmp_path, open_dataset):
inputs = [
("collection", C3S_CORDEX_MON_COLLECTION),
Expand All @@ -418,7 +403,6 @@ def test_smoke_execute_c3s_cordex_subset_by_point(wps, tmp_path, open_dataset):
assert "tas" in ds.variables


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset_original_files(wps):
inputs = [
("collection", C3S_CMIP6_DAY_COLLECTION),
Expand All @@ -431,7 +415,6 @@ def test_smoke_execute_c3s_cmip6_subset_original_files(wps):
assert "esg_c3s-cmip6" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset_collection_only(wps):
inputs = [("collection", C3S_CMIP6_DAY_COLLECTION)]
urls = wps.execute("subset", inputs)
Expand All @@ -443,7 +426,6 @@ def test_smoke_execute_c3s_cmip6_subset_collection_only(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cordex_subset_collection_only(wps):
inputs = [("collection", C3S_CORDEX_MON_COLLECTION)]
urls = wps.execute("subset", inputs)
Expand All @@ -457,7 +439,6 @@ def test_smoke_execute_c3s_cordex_subset_collection_only(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip5_subset_time_and_area_cross_meridian(wps):
inputs = [
("collection", C3S_CMIP5_MON_COLLECTION),
Expand All @@ -469,7 +450,6 @@ def test_smoke_execute_c3s_cmip5_subset_time_and_area_cross_meridian(wps):
assert "tas_mon_MPI-ESM-LR_historical_r1i1p1_20050116-20051216.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_subset_time_and_area_cross_meridian(wps):
inputs = [
("collection", C3S_CMIP6_MON_COLLECTION),
Expand All @@ -481,15 +461,13 @@ def test_smoke_execute_c3s_cmip6_subset_time_and_area_cross_meridian(wps):
assert "rlds_Amon_INM-CM5-0_ssp245_r1i1p1f1_gr1_20200116-20201216.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip5_average_dim(wps):
inputs = [("collection", C3S_CMIP5_MON_COLLECTION), ("dims", "time")]
urls = wps.execute("average", inputs)
assert len(urls) == 1
assert "tas_mon_MPI-ESM-LR_historical_r1i1p1_avg-t.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip5_average_time(wps):
inputs = [("collection", C3S_CMIP5_MON_COLLECTION), ("freq", "year")]
urls = wps.execute("average_time", inputs)
Expand All @@ -499,15 +477,13 @@ def test_smoke_execute_c3s_cmip5_average_time(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_average_dim(wps):
inputs = [("collection", C3S_CMIP6_MON_COLLECTION), ("dims", "time")]
urls = wps.execute("average", inputs)
assert len(urls) == 1
assert "rlds_Amon_INM-CM5-0_ssp245_r1i1p1f1_gr1_avg-t.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_average_time(wps):
inputs = [("collection", C3S_CMIP6_MON_COLLECTION), ("freq", "year")]
urls = wps.execute("average_time", inputs)
Expand All @@ -518,7 +494,6 @@ def test_smoke_execute_c3s_cmip6_average_time(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cordex_average_dim(wps):
inputs = [("collection", C3S_CORDEX_MON_COLLECTION), ("dims", "time")]
urls = wps.execute("average", inputs)
Expand All @@ -530,7 +505,6 @@ def test_smoke_execute_c3s_cordex_average_dim(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cordex_average_time(wps):
inputs = [("collection", C3S_CORDEX_MON_COLLECTION), ("freq", "year")]
urls = wps.execute("average_time", inputs)
Expand All @@ -542,7 +516,6 @@ def test_smoke_execute_c3s_cordex_average_time(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_weighted_average(wps):
inputs = [("collection", C3S_CMIP6_MON_COLLECTION)]
urls = wps.execute("weighted_average", inputs)
Expand All @@ -552,7 +525,6 @@ def test_smoke_execute_c3s_cmip6_weighted_average(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_regrid(wps):
inputs = [
("collection", C3S_CMIP6_MON_COLLECTION),
Expand All @@ -567,7 +539,6 @@ def test_smoke_execute_c3s_cmip6_regrid(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip5_orchestrate(wps):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CMIP5)),
Expand All @@ -577,7 +548,6 @@ def test_smoke_execute_c3s_cmip5_orchestrate(wps):
assert "tas_day_IPSL-CM5B-LR_historical_r1i1p1_avg-t.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_orchestrate(wps):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CMIP6)),
Expand All @@ -587,7 +557,6 @@ def test_smoke_execute_c3s_cmip6_orchestrate(wps):
assert "rlds_Amon_INM-CM5-0_ssp245_r1i1p1f1_gr1_avg-t.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_weighted_average_orchestrate(wps):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CMIP6_W_AVG)),
Expand All @@ -599,7 +568,6 @@ def test_smoke_execute_c3s_cmip6_weighted_average_orchestrate(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_regrid_orchestrate(wps):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CMIP6_REGRID)),
Expand All @@ -612,7 +580,6 @@ def test_smoke_execute_c3s_cmip6_regrid_orchestrate(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_360day_calendar_orchestrate(wps):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CMIP6_360DAY_CALENDAR)),
Expand All @@ -622,7 +589,6 @@ def test_smoke_execute_c3s_cmip6_360day_calendar_orchestrate(wps):
assert "pr_day_HadGEM3-GC31-LL_ssp245_r1i1p1f3_gn_20150101-20150330.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_orchestrate_metadata(wps, tmp_path, open_dataset):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CMIP6)),
Expand All @@ -647,7 +613,6 @@ def test_smoke_execute_c3s_cmip6_orchestrate_metadata(wps, tmp_path, open_datase
# assert "coordinates" not in ds.time_bnds.encoding


@pytest.mark.smoke
def test_smoke_execute_c3s_cordex_orchestrate(wps):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CORDEX)),
Expand All @@ -660,7 +625,6 @@ def test_smoke_execute_c3s_cordex_orchestrate(wps):
)


@pytest.mark.smoke
def test_smoke_execute_c3s_cmip6_decadal_orchestrate(wps):
inputs = [
("workflow", ComplexDataInput(WF_C3S_CMIP6_DECADAL)),
Expand All @@ -671,7 +635,6 @@ def test_smoke_execute_c3s_cmip6_decadal_orchestrate(wps):
assert "19951116-19951216.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_ipcc_atlas_cmip5_subset(wps):
inputs = [
("collection", C3S_IPCC_ATLAS_CMIP5_COLLECTION),
Expand All @@ -683,7 +646,6 @@ def test_smoke_execute_c3s_ipcc_atlas_cmip5_subset(wps):
assert "tnn_CMIP5_rcp45_mon_200601-210012.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_ipcc_atlas_cmip6_subset(wps):
inputs = [
("collection", C3S_IPCC_ATLAS_CMIP6_COLLECTION),
Expand All @@ -695,7 +657,6 @@ def test_smoke_execute_c3s_ipcc_atlas_cmip6_subset(wps):
assert "tnn_CMIP6_historical_mon_185001-201412.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_ipcc_atlas_cordex_subset(wps):
inputs = [
("collection", C3S_IPCC_ATLAS_CORDEX_COLLECTION),
Expand All @@ -707,7 +668,6 @@ def test_smoke_execute_c3s_ipcc_atlas_cordex_subset(wps):
assert "tnn_CORDEX-AFR_historical_mon_197001-200512.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cica_atlas_cmip6_subset(wps):
inputs = [
("collection", C3S_CICA_ATLAS_CMIP6_COLLECTION),
Expand All @@ -719,7 +679,6 @@ def test_smoke_execute_c3s_cica_atlas_cmip6_subset(wps):
assert "cd_CMIP6_historical_yr_20000101-20000101.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cica_atlas_cordex_subset(wps):
inputs = [
("collection", C3S_CICA_ATLAS_CORDEX_COLLECTION),
Expand All @@ -731,7 +690,6 @@ def test_smoke_execute_c3s_cica_atlas_cordex_subset(wps):
assert "cdd_CORDEX-CORE_historical_yr_20000101-20000101.nc" in urls[0]


@pytest.mark.smoke
def test_smoke_execute_c3s_cica_atlas_era5_subset_no_time_param(wps):
inputs = [
("collection", C3S_CICA_ATLAS_ERA5_COLLECTION),
Expand Down

0 comments on commit 16e4f44

Please sign in to comment.