summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/internals/yaml.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/internals/yaml.py b/tests/internals/yaml.py
index 5c1383a25..c505fbd20 100644
--- a/tests/internals/yaml.py
+++ b/tests/internals/yaml.py
@@ -166,7 +166,9 @@ def load_yaml_file(filename, *, cache_path, shortname=None, from_cache='raw'):
_yaml.load(filename, shortname, yaml_cache=yc)
return _yaml.load(filename, shortname, yaml_cache=yc)
else:
- assert False
+ raise Exception(
+ "Invalid value for parameter 'from_cache', Expected 'raw' or 'cached'"
+ )
# Tests for list composition