Skip to content

Commit

Permalink
fix: terminate etcd process after running tests (#2359)
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Hahn <chahn@livinglogic.de>
Co-authored-by: Christian Hahn <chahn@livinglogic.de>
  • Loading branch information
chahn and chahn committed May 31, 2023
1 parent 57153a7 commit b4df29a
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions etcd/etcd_test.go
Expand Up @@ -26,14 +26,14 @@ func TestMain(m *testing.M) {
log.Fatal(err)
}

defer func() {
err := etcdtest.Stop()
if err != nil {
log.Fatal(err)
}
}()
exitCode := m.Run()

err = etcdtest.Stop()
if err != nil {
log.Fatal(err)
}

os.Exit(m.Run())
os.Exit(exitCode)
}

func checkInitial(d []*eskip.Route) bool {
Expand Down

0 comments on commit b4df29a

Please sign in to comment.