fix admin_test not closing correct servers (#30531)
Этот коммит содержится в:
@@ -67,7 +67,7 @@ func TestGetLatestVersion(t *testing.T) {
|
|||||||
_, err := w.Write(updatedJSON)
|
_, err := w.Write(updatedJSON)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
}))
|
}))
|
||||||
defer ts.Close()
|
defer updatedServer.Close()
|
||||||
|
|
||||||
cachedResult, appErr := th.App.GetLatestVersion(th.Context, updatedServer.URL)
|
cachedResult, appErr := th.App.GetLatestVersion(th.Context, updatedServer.URL)
|
||||||
require.Nil(t, appErr)
|
require.Nil(t, appErr)
|
||||||
@@ -88,7 +88,7 @@ func TestGetLatestVersion(t *testing.T) {
|
|||||||
`))
|
`))
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
}))
|
}))
|
||||||
defer ts.Close()
|
defer errorServer.Close()
|
||||||
|
|
||||||
_, appErr := th.App.GetLatestVersion(th.Context, errorServer.URL)
|
_, appErr := th.App.GetLatestVersion(th.Context, errorServer.URL)
|
||||||
require.NotNil(t, appErr)
|
require.NotNil(t, appErr)
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user