File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed
tests/acceptance/01_vars/01_basic Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change
1
+ body common control
2
+ {
3
+ bundlesequence => { "test" };
4
+ }
5
+
6
+
7
+ bundle agent test
8
+ {
9
+ vars:
10
+ "release_id_list" slist => variablesmatching("default:sys.policy_release_id");
11
+ "escaped" string => escape("$(sys.policy_entry_dirname)");
12
+ "release_id_regex" string => "^$(escaped)\/([A-Fa-f0-9]+|bootstrap|failsafe|\(null\))+$";
13
+
14
+ classes:
15
+ "var_ok" expression => strcmp("$(release_id_list)", "default:sys.policy_release_id");
16
+ "reg_ok" expression => regcmp("$(release_id_regex)", "$(sys.policy_release_id)");
17
+ "ok" expression => and("var_ok", "reg_ok");
18
+
19
+ reports:
20
+ DEBUG::
21
+ "Found: $(release_id_list), Correct: $(sys.policy_release_id)";
22
+ DEBUG.var_ok::
23
+ "var ok";
24
+ DEBUG.reg_ok::
25
+ "reg_ok";
26
+ ok::
27
+ "$(this.promise_filename) Pass";
28
+ !ok::
29
+ "$(this.promise_filename) FAIL";
30
+ }
You can’t perform that action at this time.
0 commit comments