mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Fix leaked connections in integration tests
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
This commit is contained in:
parent
c38bb7a725
commit
1e98fb5ad9
9 changed files with 28 additions and 6 deletions
|
@ -38,6 +38,7 @@ func makefile(contents string) (string, func(), error) {
|
|||
// attempt to contact any v1 registry endpoints.
|
||||
func (s *DockerRegistrySuite) TestV2Only(c *check.C) {
|
||||
reg, err := registry.NewMock(c)
|
||||
defer reg.Close()
|
||||
c.Assert(err, check.IsNil)
|
||||
|
||||
reg.RegisterHandler("/v2/", func(w http.ResponseWriter, r *http.Request) {
|
||||
|
@ -70,6 +71,7 @@ func (s *DockerRegistrySuite) TestV2Only(c *check.C) {
|
|||
// login, push, pull, build & run
|
||||
func (s *DockerRegistrySuite) TestV1(c *check.C) {
|
||||
reg, err := registry.NewMock(c)
|
||||
defer reg.Close()
|
||||
c.Assert(err, check.IsNil)
|
||||
|
||||
v2Pings := 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue