MCPcopy
hub / github.com/docker/compose / TestCascadeStop

Function TestCascadeStop

pkg/e2e/cascade_test.go:28–40  ·  pkg/e2e/cascade_test.go::TestCascadeStop
(t *testing.T)

Source from the content-addressed store, hash-verified

26)
27
28func TestCascadeStop(t *testing.T) {
29 c := NewCLI(t)
30 const projectName = "compose-e2e-cascade-stop"
31 t.Cleanup(func() {
32 c.RunDockerComposeCmd(t, "--project-name", projectName, "down")
33 })
34
35 res := c.RunDockerComposeCmd(t, "-f", "./fixtures/cascade/compose.yaml", "--project-name", projectName,
36 "up", "--abort-on-container-exit")
37 assert.Assert(t, strings.Contains(res.Combined(), "exit-1 exited with code 0"), res.Combined())
38 // no --exit-code-from, so this is not an error
39 assert.Equal(t, res.ExitCode, 0)
40}
41
42func TestCascadeFail(t *testing.T) {
43 c := NewCLI(t)

Callers

nothing calls this directly

Calls 2

RunDockerComposeCmdMethod · 0.95
NewCLIFunction · 0.85

Tested by

no test coverage detected