Skip to content

Commit 26e3153

Browse files
committed
prevent teardown panic if test fails
Signed-off-by: Alex Suraci <[email protected]>
1 parent 573c3a9 commit 26e3153

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Diff for: buildkitd_test.go

+4-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,10 @@ type BuildkitdSuite struct {
2222
}
2323

2424
func (s *BuildkitdSuite) TearDownSuite() {
25-
err := s.buildkitd.Cleanup()
26-
s.NoError(err)
25+
if s.buildkitd != nil {
26+
err := s.buildkitd.Cleanup()
27+
s.NoError(err)
28+
}
2729
}
2830

2931
func (s *BuildkitdSuite) SetupTest() {

0 commit comments

Comments
 (0)