github.com/upcmd/up@v0.8.1-0.20230108151705-ad8b797bf04f/tests/functests/f0031.yml (about) 1 goal: 2 - refdir will override global configured refdir 3 - it will error if refdir for dvar is not correct 4 5 expected: 6 - school object in nonprod could append new element and 7 - also override same name element 8 9 scopes: 10 - 11 name: global 12 vars: 13 student: 14 name: Tom 15 gender: Male 16 address: 17 suburb: 18 name: sydney 19 postcode: 2000 20 CBD: yes 21 school: Sydney Grammar 22 23 dvars: 24 - name: school 25 value: | 26 address: 27 suburb: 28 name: {{.student.address.suburb.name}} 29 postcode: 2000 30 CBD: yes 31 school: {{.student.address.school}} 32 flags: [toObj] 33 34 - 35 name: nonprod 36 members: 37 - dev 38 - staging 39 vars: 40 a: non-prod-a 41 b: non-prod-b 42 c: non-prod-c 43 d: non-prod-d 44 dvars: 45 - name: school 46 value: | 47 address: 48 suburb: 49 name: {{.student.address.suburb.name}} 50 postcode: 2000 51 CBD: no 52 school: {{.student.address.school}} 53 principal: Mr Peter 54 flags: [toObj] 55 56 - 57 name: dev 58 vars: 59 a: dev-a 60 b: dev-b 61 62 63 dvars: 64 - name: sgp_address 65 ref: d0030_school.yml 66 refdir: ./tests 67 flags: [toObj] 68 69 tasks: 70 71 - 72 name: task 73 task: 74 - 75 func: shell 76 do: 77 - echo """1.school -> {{.school}}""" 78 - echo """2.school object-> {{.school_object.address.suburb.CBD}}""" 79 - echo """3.school object-> {{.school_object.address.school}}""" 80 - echo """4.school object-> {{.school_object.principal}}"""