1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

add cleanupin tests to remove leftover containers

This commit is contained in:
Victor Vieux 2013-10-16 18:06:37 +00:00
parent 0ca533ca35
commit f854529ae8

View file

@ -94,6 +94,13 @@ func init() {
globalRuntime = runtime
}
// Cleanup any leftover container
for _, container := range globalRuntime.List() {
if err := globalRuntime.Destroy(container); err != nil {
log.Fatalf("Error destroying leftover container: %s", err)
}
}
// Create the "Server"
srv := &Server{
runtime: globalRuntime,