summaryrefslogtreecommitdiffstats
path: root/tests/yamlparser/fixtures
diff options
context:
space:
mode:
Diffstat (limited to 'tests/yamlparser/fixtures')
-rw-r--r--tests/yamlparser/fixtures/variable_escaping.xml23
-rw-r--r--tests/yamlparser/fixtures/variable_escaping.yaml17
2 files changed, 40 insertions, 0 deletions
diff --git a/tests/yamlparser/fixtures/variable_escaping.xml b/tests/yamlparser/fixtures/variable_escaping.xml
new file mode 100644
index 00000000..16a37dd2
--- /dev/null
+++ b/tests/yamlparser/fixtures/variable_escaping.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<project>
+ <actions/>
+ <description>&lt;!-- Managed by Jenkins Job Builder --&gt;</description>
+ <keepDependencies>false</keepDependencies>
+ <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
+ <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
+ <concurrentBuild>false</concurrentBuild>
+ <canRoam>true</canRoam>
+ <properties/>
+ <scm class="hudson.scm.NullSCM"/>
+ <builders>
+ <hudson.tasks.Shell>
+ <command>echo &quot;{var}&quot;
+echo &quot;{defined_var|def}&quot;
+echo &quot;{undefined_var|def}&quot;
+echo &quot;{undefined_var|defined_var}&quot;
+</command>
+ </hudson.tasks.Shell>
+ </builders>
+ <publishers/>
+ <buildWrappers/>
+</project>
diff --git a/tests/yamlparser/fixtures/variable_escaping.yaml b/tests/yamlparser/fixtures/variable_escaping.yaml
new file mode 100644
index 00000000..44e8f7b4
--- /dev/null
+++ b/tests/yamlparser/fixtures/variable_escaping.yaml
@@ -0,0 +1,17 @@
+- project:
+ name: test_template_variable_escaping
+ jobs:
+ - 'template_variable_escaping':
+ defined_var: 'Hello'
+
+- job-template:
+ name: 'template_variable_escaping'
+ builders:
+ - shell: |
+ echo "{{var}}"
+ echo "{{defined_var|def}}"
+ echo "{{undefined_var|def}}"
+ echo "{{undefined_var|defined_var}}"
+
+
+