diff --git a/openmetadata-ui/src/main/resources/ui/src/components/ActivityFeed/ActivityFeedList/ActivityFeedList.test.tsx b/openmetadata-ui/src/main/resources/ui/src/components/ActivityFeed/ActivityFeedList/ActivityFeedList.test.tsx index 344d3fffe45..7905da69949 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/ActivityFeed/ActivityFeedList/ActivityFeedList.test.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/ActivityFeed/ActivityFeedList/ActivityFeedList.test.tsx @@ -11,7 +11,7 @@ * limitations under the License. */ -import { findByTestId, render } from '@testing-library/react'; +import { findByTestId, queryByTestId, render } from '@testing-library/react'; import React from 'react'; import { MemoryRouter } from 'react-router-dom'; import ActivityFeedList from './ActivityFeedList'; @@ -85,6 +85,10 @@ jest.mock('../NoFeedPlaceholder/NoFeedPlaceholder', () => { return jest.fn().mockReturnValue(
NoFeedPlaceholder
); }); +jest.mock('../../common/error-with-placeholder/ErrorPlaceHolder', () => { + return jest.fn().mockReturnValue(ErrorPlaceHolder
); +}); + jest.mock('./FeedListBody', () => { return jest.fn().mockReturnValue(FeedListBody
); }); @@ -115,4 +119,40 @@ describe('Test FeedList Component', () => { expect(feed1).toBeInTheDocument(); expect(feed2).toBeInTheDocument(); }); + + it('No data placeholders should not displayed if feedList is empty but feeds are loading', async () => { + const { container } = render( +