Commit graph

7 commits

Author SHA1 Message Date
Ravi Srinivasa
8abacb694f
test: Add test suite and documentation for custom variable and dictionary support
Tests covering:
- CustomVariable / CustomVariables: rendering, config string generation,
  dictionary and array type behaviour
- CustomVariableDictionaryRendering: Icinga 2 DSL output for nested dicts
- IcingaConfigHelper: macro validation and structured variable rendering
- DirectorProperty: CRUD, inheritance, field assignment
- IcingaHost / IcingaService / IcingaServiceApplyFor: object-level
  custom variable assignment and apply-for rule evaluation
- BasketSnapshotCustomVariable: round-trip basket import/export
- MigrateCommand: migration logic, --delete, --dry-run, skipped fields
- CustomVariableForm / CustomVariablesForm / DeleteCustomVariableForm:
  form submission and validation
- Rendered output fixtures updated for service5/6/7 and new
  host_dynamic_dict, service_apply_for_array, service_apply_for_dict

Documentation:
- Dictionary-Support-Changes.md: full feature overview and API reference
- custom-variables-demo.sh: end-to-end shell demo script
2026-06-01 12:32:15 +02:00
Thomas Gelf
b475aa841e IcingaConfigHelper: granular macro-rendering
fixes #685
fixes #1272
fixes #1482
2018-06-04 18:18:32 +02:00
Thomas Gelf
15e87a15bb CustomVariables: fix and test numeric key rendering
fixes #996
2017-07-14 13:21:42 +02:00
Corentin Ardeois
37c91050c7 Expressions syntax is now $var$
Instead of $$var$$.
We make sure $$var$$ is left untouched.

refs #11976
2016-10-22 00:15:09 +00:00
Corentin Ardeois
ddcfb09f58 Handle expressions only for apply objects
Expressions will be handled only if the object is an ApplyRule.
Only properties and custom variables are replaced.

refs #11976
2016-10-22 00:15:09 +00:00
Thomas Gelf
d915bb25f7 CustomVariablesTest: testVarsCanBeUnsetAndSetAgain 2016-09-08 23:13:48 +00:00
Thomas Gelf
4e083d7d40 CustomVariables: use array notation for keys...
...with special characters
2016-07-22 18:09:02 +02:00