Skip to content
This repository was archived by the owner on Jul 18, 2025. It is now read-only.

Commit a518c78

Browse files
committed
Fix TestPushInstallBundle
Signed-off-by: Nicolas De Loof <[email protected]>
1 parent e5fea9d commit a518c78

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

e2e/pushpull_test.go

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ import (
1818
v1 "github.com/opencontainers/image-spec/specs-go/v1"
1919
"gotest.tools/assert"
2020
"gotest.tools/assert/cmp"
21-
"gotest.tools/fs"
2221
"gotest.tools/icmd"
2322
)
2423

@@ -189,18 +188,14 @@ func TestPushInstallBundle(t *testing.T) {
189188
cmd := info.configuredCmd
190189
ref := info.registryAddress + "/test/push-bundle"
191190

192-
tmpDir := fs.NewDir(t, t.Name())
193-
defer tmpDir.Remove()
194-
bundleFile := tmpDir.Join("bundle.json")
195-
196191
// render the app to a bundle, we use the app from the push pull test above.
197-
cmd.Command = dockerCli.Command("app", "build", "-o", bundleFile, filepath.Join("testdata", "push-pull", "push-pull.dockerapp"), "a-simple-app")
192+
cmd.Command = dockerCli.Command("app", "build", filepath.Join("testdata", "push-pull", "push-pull.dockerapp"), "a-simple-app:1.0.0")
198193
icmd.RunCmd(cmd).Assert(t, icmd.Success)
199194

200195
// push it and install to check it is available
201196
t.Run("push-bundle", func(t *testing.T) {
202197
name := strings.Replace(t.Name(), "/", "_", 1)
203-
cmd.Command = dockerCli.Command("app", "push", "--tag", ref, bundleFile)
198+
cmd.Command = dockerCli.Command("app", "push", "--tag", ref, "a-simple-app:1.0.0")
204199
icmd.RunCmd(cmd).Assert(t, icmd.Success)
205200

206201
cmd.Command = dockerCli.Command("app", "install", ref, "--pull", "--name", name)

internal/commands/build/build.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,8 @@ func runBuild(dockerCli command.Cli, application string, opt buildOptions) (refe
9898

9999
ctx, cancel := context.WithCancel(appcontext.Context())
100100
defer cancel()
101-
d, err := driver.GetDriver(ctx, "buildx_buildkit_default", nil, dockerCli.Client(), nil, "", nil)
101+
const drivername = "buildx_buildkit_default"
102+
d, err := driver.GetDriver(ctx, drivername, nil, dockerCli.Client(), nil, "", nil)
102103
if err != nil {
103104
return nil, err
104105
}

0 commit comments

Comments
 (0)