Skip to content

Commit 3730d98

Browse files
Fix order of available projects in test_recipe (#3023)
Co-authored-by: Bouwe Andela <b.andela@esciencecenter.nl>
1 parent c81a024 commit 3730d98

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

tests/integration/recipe/test_recipe.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3888,14 +3888,13 @@ def test_align_metadata_invalid_project(tmp_path, patched_datafinder, session):
38883888
""")
38893889
msg = (
38903890
"align_metadata failed: \"No CMOR tables available for project 'ZZZ'. "
3891-
"The following tables are available: CMIP7, CMIP6, CMIP5, CMIP3, "
3892-
"CORDEX, obs4MIPs, ana4MIPs, native6, ACCESS, CESM, EMAC, ICON, IPSLCM, "
3893-
'OBS6, OBS."'
3891+
'The following tables are available: .*."'
38943892
)
38953893
with pytest.raises(RecipeError) as exc:
38963894
get_recipe(tmp_path, content, session)
38973895
assert str(exc.value) == INITIALIZATION_ERROR_MSG
3898-
assert exc.value.failed_tasks[0].message == msg
3896+
assert re.match(msg, exc.value.failed_tasks[0].message)
3897+
assert "CMIP7" in exc.value.failed_tasks[0].message
38993898

39003899

39013900
def test_align_metadata_invalid_name(tmp_path, patched_datafinder, session):

0 commit comments

Comments
 (0)