From 1c71000c16902d0ba2ca0f05f8b407eeaf554b97 Mon Sep 17 00:00:00 2001 From: mjac0bs Date: Wed, 31 Jan 2024 10:13:32 -0700 Subject: [PATCH] Fix unit test failure --- .../Account/SwitchAccounts/ChildAccountList.test.tsx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/packages/manager/src/features/Account/SwitchAccounts/ChildAccountList.test.tsx b/packages/manager/src/features/Account/SwitchAccounts/ChildAccountList.test.tsx index 63dd01d786f..555a6ee0801 100644 --- a/packages/manager/src/features/Account/SwitchAccounts/ChildAccountList.test.tsx +++ b/packages/manager/src/features/Account/SwitchAccounts/ChildAccountList.test.tsx @@ -1,8 +1,7 @@ import { waitFor, within } from '@testing-library/react'; import * as React from 'react'; -import { accountFactory } from 'src/factories/account'; -import { accountUserFactory } from 'src/factories/accountUsers'; +import { accountFactory, profileFactory } from 'src/factories'; import { ChildAccountList } from 'src/features/Account/SwitchAccounts/ChildAccountList'; import { makeResourcePage } from 'src/mocks/serverHandlers'; import { rest, server } from 'src/mocks/testServer'; @@ -17,8 +16,8 @@ const props = { it('should display a list of child accounts', async () => { server.use( - rest.get('*/account/users/*', (req, res, ctx) => { - return res(ctx.json(accountUserFactory.build({ user_type: 'parent' }))); + rest.get('*/profile', (req, res, ctx) => { + return res(ctx.json(profileFactory.build({ user_type: 'parent' }))); }), rest.get('*/account/child-accounts', (req, res, ctx) => { return res(