From e6498f72e3010f2a9b474f55a82724f35185203d Mon Sep 17 00:00:00 2001 From: Nick De Villiers Date: Mon, 25 Mar 2024 12:51:06 +0000 Subject: [PATCH] re-initialise store in redirect test in DeleteSubnet --- .../components/DeleteSubnet/DeleteSubnet.test.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/subnets/views/SubnetDetails/SubnetDetailsHeader/SubnetActionForms/components/DeleteSubnet/DeleteSubnet.test.tsx b/src/app/subnets/views/SubnetDetails/SubnetDetailsHeader/SubnetActionForms/components/DeleteSubnet/DeleteSubnet.test.tsx index cbc29ad8e17..767f163b60b 100644 --- a/src/app/subnets/views/SubnetDetails/SubnetDetailsHeader/SubnetActionForms/components/DeleteSubnet/DeleteSubnet.test.tsx +++ b/src/app/subnets/views/SubnetDetails/SubnetDetailsHeader/SubnetActionForms/components/DeleteSubnet/DeleteSubnet.test.tsx @@ -179,7 +179,7 @@ it("redirects on save", async () => { }); const state = getRootState(); state.vlan.items[0].dhcp_on = false; - const store = configureStore()(state); + let store = configureStore()(state); const { rerender } = render( @@ -198,6 +198,7 @@ it("redirects on save", async () => { ); state.subnet.saved = true; + store = configureStore()(state); rerender(