sh
description =
check: Ensure that auto-generated files matches the current version
- fix: Update generated files from jsonnet filse with latest changes
+ fix: Update generated files from jsonnet file with latest changes
lint: Test if jsonnet files are linted (without any update)
deps =
-rrequirements-grafonnet.txt
commands =
behave tests_dashboards/features
-[testenv:alerts-{check,lint}]
+[testenv:alerts-{fix,check,lint}]
deps =
-rrequirements-alerts.txt
pytest
whitelist_externals =
promtool
commands =
+ fix: jsonnet -J vendor -S alerts.jsonnet -o prometheus_alerts.yml
lint: promtool check rules prometheus_alerts.yml
test: pytest -rA tests_alerts/test_syntax.py tests_alerts/test_unittests.py
python3 ./tests_alerts/validate_rules.py