mirror of
https://github.com/go-task/task.git
synced 2025-01-04 03:48:02 +02:00
remove unnecassry test for multiple summaries
This commit is contained in:
parent
93bfd57856
commit
808542bed0
@ -566,15 +566,8 @@ func TestSummary(t *testing.T) {
|
||||
Silent: true,
|
||||
}
|
||||
assert.NoError(t, e.Setup())
|
||||
assert.NoError(t, e.Run(context.Background(), taskfile.Call{Task: "task-with-summary"}))
|
||||
assert.NoError(t, e.Run(context.Background(), taskfile.Call{Task: "task-with-summary"}, taskfile.Call{Task: "other-task-with-summary"}))
|
||||
assert.Equal(t, readTestFixture(t, dir, "task-with-summary.txt"), buff.String())
|
||||
|
||||
buff.Reset()
|
||||
const firstTask = "other-task-with-summary"
|
||||
const secondTask = "task-with-summary"
|
||||
assert.NoError(t, e.Run(context.Background(), taskfile.Call{Task: firstTask}, taskfile.Call{Task: secondTask}))
|
||||
assert.Contains(t, buff.String(), "summary of "+firstTask)
|
||||
assert.Contains(t, buff.String(), "summary of "+secondTask)
|
||||
}
|
||||
|
||||
func readTestFixture(t *testing.T, dir string, file string) string {
|
||||
|
6
testdata/summary/task-with-summary.txt
vendored
6
testdata/summary/task-with-summary.txt
vendored
@ -12,3 +12,9 @@ commands:
|
||||
- echo 'task-with-summary was executed'
|
||||
- echo 'another command'
|
||||
- exit 0
|
||||
task: other-task-with-summary
|
||||
|
||||
summary of other-task-with-summary
|
||||
|
||||
commands:
|
||||
- echo 'other-task-with-summary was executed'
|
||||
|
Loading…
Reference in New Issue
Block a user