Skip to content

Commit

Permalink
Prevent teardown in ugprade tests on failure (#5624)
Browse files Browse the repository at this point in the history
* Prevent teardown in ugprade tests on failure

* Re-run github action
  • Loading branch information
mgencur authored Aug 5, 2021
1 parent 8551625 commit ca9e469
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/upgrade/prober/prober.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,6 @@ func (p *probeRunner) Verify(ctx pkgupgrade.Context) {
// use T from new test
p.client.T = ctx.T
t := ctx.T
defer testlib.TearDown(p.client)
defer p.remove()
p.Finish()
waitAfterFinished(p.prober)

Expand All @@ -80,6 +78,10 @@ func (p *probeRunner) Verify(ctx pkgupgrade.Context) {
}

p.ReportErrors(errors)
if !ctx.T.Failed() {
p.remove()
testlib.TearDown(p.client)
}
}

type prober struct {
Expand Down

0 comments on commit ca9e469

Please sign in to comment.