1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-19 05:19:39 +02:00

chore(unit-test): simplify teardown EE-5536 (#9015)

This commit is contained in:
andres-portainer 2023-05-30 11:02:22 -03:00 committed by GitHub
parent b498cd657f
commit eda07614ce
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
37 changed files with 110 additions and 218 deletions

View file

@ -13,8 +13,7 @@ import (
// Update Status
func TestUpdateStatusAndInspect(t *testing.T) {
handler, rawAPIKey, teardown := setupHandler(t)
defer teardown()
handler, rawAPIKey := setupHandler(t)
endpoint := createEndpoint(t, handler.DataStore)
edgeStack := createEdgeStack(t, handler.DataStore, endpoint.ID)
@ -79,8 +78,7 @@ func TestUpdateStatusAndInspect(t *testing.T) {
}
}
func TestUpdateStatusWithInvalidPayload(t *testing.T) {
handler, _, teardown := setupHandler(t)
defer teardown()
handler, _ := setupHandler(t)
endpoint := createEndpoint(t, handler.DataStore)
edgeStack := createEdgeStack(t, handler.DataStore, endpoint.ID)