1
0
mirror of https://github.com/go-task/task.git synced 2025-11-23 22:24:45 +02:00
Files
task/testdata/params/Taskfile.yml
Pete Davison 4736bc2734 refactor: unify how executor tests are written (#2042)
* feat: use TaskTest for executor tests

* feat: more tests

* feat: separate tests for executing and formatting with new functional options that work for both test types

* feat: formatter tests

* refactor: more tests
2025-03-31 17:53:58 +01:00

45 lines
1.0 KiB
YAML

version: '3'
vars:
PORTUGUESE_HELLO_WORLD: Olá, mundo!
GERMAN: Hello
tasks:
default:
vars:
SPANISH: ¡Holla mundo!
PORTUGUESE: "{{.PORTUGUESE_HELLO_WORLD}}"
GERMAN: "Welt!"
deps:
- task: write-file
vars: {CONTENT: Dependence1}
- task: write-file
vars: {CONTENT: Dependence2}
- task: write-file
vars: {CONTENT: "{{.SPANISH|replace \"mundo\" \"dependencia\"}}"}
cmds:
- task: write-file
vars: {CONTENT: Hello}
- task: write-file
vars: {CONTENT: "$echo 'World'"}
- task: write-file
vars: {CONTENT: "!"}
- task: write-file
vars: {CONTENT: "{{.SPANISH}}"}
- task: write-file
vars: {CONTENT: "{{.PORTUGUESE}}"}
- task: write-file
vars: {CONTENT: "{{.GERMAN}}"}
- task: non-default
write-file:
cmds:
- echo {{.CONTENT}}
non-default:
vars:
PORTUGUESE: "{{.PORTUGUESE_HELLO_WORLD}}"
cmds:
- task: write-file
vars: {CONTENT: "{{.PORTUGUESE}}"}