Based on the feedback from Tomáš in [0] this commit adds tests that ensure consistent behavior between the python and the json loader. It's not 100% because the python is extremly leaniant and does not even check if the required pieces of the json are there. I.e. it will load a module without a SCHEMA or SCHEMA_2 variable and the json loader code will warn about the issue but not raise an error. Fwiw, I have no strong opinion here but I do lean slightly towards staying close to the original code (but both approaches of failing with an exectption and continue with a warning have good arguments). [0] https://github.com/osbuild/osbuild/pull/1618#discussion_r1521141148 |
||
|---|---|---|
| .. | ||
| cases | ||
| data | ||
| mod | ||
| run | ||
| stages | ||
| .gitignore | ||
| __init__.py | ||
| conftest.py | ||
| initrd.py | ||
| test.py | ||