diff --git a/internal/commands/test_tile.go b/internal/commands/test_tile.go index e05948e4..edf03a57 100644 --- a/internal/commands/test_tile.go +++ b/internal/commands/test_tile.go @@ -23,7 +23,7 @@ type TileTest struct { Manifest bool ` long:"manifest" default:"false" description:"Focus the Manifest tests."` Migrations bool ` long:"migrations" default:"false" description:"Focus the Migration tests."` Stability bool ` long:"stability" default:"false" description:"Focus the Stability tests."` - ImagePath string " long:\"image-path\" " + ImagePath string ` long:"image-path" ` EnvironmentVars []string `short:"e" long:"environment-variable" description:"Pass environment variable to the test suites. For example --stability -e 'PRODUCT=srt'."` GingkoFlags string ` long:"ginkgo-flags" default:"-r -p -slowSpecThreshold 15" description:"Flags to pass to the Ginkgo Manifest and Stability test suites."` } diff --git a/internal/test/container.go b/internal/test/container.go index 8f8bfa9b..67a4b5b2 100644 --- a/internal/test/container.go +++ b/internal/test/container.go @@ -174,9 +174,8 @@ func runTestWithSession(ctx context.Context, logger *log.Logger, w io.Writer, do if err != nil { return fmt.Errorf("failed to import image: %w", err) } - + defer closeAndIgnoreError(loadResponse.Body) respBytes, err := io.ReadAll(loadResponse.Body) - defer loadResponse.Body.Close() if err != nil { return fmt.Errorf(`failed to parse load image response: %w`, err) } diff --git a/internal/test/container_test.go b/internal/test/container_test.go index a4db0646..35dc1c4a 100644 --- a/internal/test/container_test.go +++ b/internal/test/container_test.go @@ -132,7 +132,7 @@ func Test_loadImage(t *testing.T) { configuration := Configuration{ AbsoluteTileDirectory: absoluteTileDirectory, - ImagePath: `assets/alpine.tgz`, + ImagePath: "assets/alpine.tgz", } client := runTestWithSessionHelper(t, "", container.WaitResponse{