mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Add unit test for #174 Delete image already deleted then repulled
This commit is contained in:
parent
069918e1fd
commit
baea0a98f8
1 changed files with 8 additions and 0 deletions
|
@ -158,6 +158,14 @@ func TestDelete(t *testing.T) {
|
|||
}
|
||||
assertNImages(graph, t, 1)
|
||||
|
||||
// Test delete twice (pull -> rm -> pull -> rm)
|
||||
if err := graph.Register(archive, img1); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
if err := graph.Delete(img1.Id); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
assertNImages(graph, t, 1)
|
||||
}
|
||||
|
||||
func assertNImages(graph *Graph, t *testing.T, n int) {
|
||||
|
|
Loading…
Reference in a new issue