jenkins-job-builder/tests/yamlparser/job_fixtures/macro-uses-global-defaults.yaml
Vsevolod Fedorov fb913725e2 Macro now use parameters from defaults
Also fix error message for missing defaults.

Change-Id: I5d912c2bfb607c8388010ac6e39780be93073f5a
2024-03-19 11:39:37 +03:00

35 lines
881 B
YAML

# Macros use global defaults.
- defaults:
name: global
global_param: sample global param value
- builder:
name: builder-without-params
builders:
- shell: |
echo "builder-without-params: Should be expanded: {global_param}"
- shell: !include-raw-expand: macro-uses-global-defaults.yaml.inc
- builder:
name: builder-with-params
builders:
- shell: |
echo "builder-with-params: Should be expanded: {param}"
- shell: |
echo "builder-with-params: Should be expanded: {global_param}"
- shell: !include-raw-expand: macro-uses-global-defaults.yaml.inc
- job-template:
name: sample-job-template
display-name: sample-job-template
builders:
- builder-without-params
- builder-with-params:
param: sample macro param value
- project:
name: sample-project
jobs:
- sample-job-template