diff --git a/generate_parameter_library_py/generate_parameter_library_py/test/YAML_parse_error_test.py b/generate_parameter_library_py/generate_parameter_library_py/test/YAML_parse_error_test.py index 7afb837..aad425c 100644 --- a/generate_parameter_library_py/generate_parameter_library_py/test/YAML_parse_error_test.py +++ b/generate_parameter_library_py/generate_parameter_library_py/test/YAML_parse_error_test.py @@ -81,6 +81,11 @@ def set_up(yaml_test_file): ], ) def test_expected(test_input, expected): + if sys.flags.optimize: + if test_input == 'wrong_default_type.yaml': + pytest.skip( + 'Evaluating optimized type validation cannot be completed when python is optimized' + ) with pytest.raises(expected) as e: yaml_test_file = test_input set_up(yaml_test_file)