MCPcopy Create free account
hub / github.com/docker/cli / testUpdater

Method testUpdater

cli/command/service/progress/progress_test.go:36–43  ·  view source on GitHub ↗
(tasks []swarm.Task, expectedConvergence bool, expectedProgress []progress.Progress)

Source from the content-addressed store, hash-verified

34}
35
36func (u updaterTester) testUpdater(tasks []swarm.Task, expectedConvergence bool, expectedProgress []progress.Progress) {
37 u.p.clear()
38
39 converged, err := u.updater.update(u.service, tasks, u.activeNodes, u.rollback)
40 assert.Check(u.t, err)
41 assert.Check(u.t, is.Equal(expectedConvergence, converged))
42 assert.Check(u.t, is.DeepEqual(expectedProgress, u.p.p))
43}
44
45func (u updaterTester) testUpdaterNoOrder(tasks []swarm.Task, expectedConvergence bool, expectedProgress []progress.Progress) {
46 u.p.clear()

Calls 2

updateMethod · 0.65
clearMethod · 0.45

Tested by

no test coverage detected