mirror of
https://github.com/docker/compose.git
synced 2026-10-12 02:13:08 +00:00
fix(e2e): drop the wantAbs alias in BindMountSource
wantAbs was just wantSource under a different name, left over from an earlier revision. Use wantSource directly. (glours review on #14234) Signed-off-by: Nicolas De Loof <[email protected]>
This commit is contained in:
committed by
Guillaume Lours
parent
0591c9b3b6
commit
cd9dd56517
+2
-3
@@ -571,7 +571,6 @@ func BindMountSource(service, target, wantSource string) Check {
|
||||
if len(containers) == 0 {
|
||||
return errors.New("service has no container")
|
||||
}
|
||||
wantAbs := wantSource
|
||||
for _, c := range containers {
|
||||
res := icmd.RunCmd(ctx.scenario.cli.NewDockerCmd(ctx.scenario.t, "inspect", "--format", "{{json .Mounts}}", c.ID))
|
||||
if res.ExitCode != 0 {
|
||||
@@ -594,8 +593,8 @@ func BindMountSource(service, target, wantSource string) Check {
|
||||
continue
|
||||
}
|
||||
found = true
|
||||
if m.Source != wantAbs {
|
||||
return fmt.Errorf("container %s mount %s resolves to %s, want %s", c.Name, target, m.Source, wantAbs)
|
||||
if m.Source != wantSource {
|
||||
return fmt.Errorf("container %s mount %s resolves to %s, want %s", c.Name, target, m.Source, wantSource)
|
||||
}
|
||||
break
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user