From c454bd06ff666381de760d94580129c68b016561 Mon Sep 17 00:00:00 2001 From: Mark Dunphy Date: Wed, 14 May 2025 13:44:03 -0400 Subject: [PATCH] remove unnecessary test cases Signed-off-by: Mark Dunphy --- .../EntityContextMenuItemBlueprint.test.tsx | 85 ------------------- 1 file changed, 85 deletions(-) diff --git a/plugins/catalog-react/src/alpha/blueprints/EntityContextMenuItemBlueprint.test.tsx b/plugins/catalog-react/src/alpha/blueprints/EntityContextMenuItemBlueprint.test.tsx index 6c0efb84dd..e15eb8a89c 100644 --- a/plugins/catalog-react/src/alpha/blueprints/EntityContextMenuItemBlueprint.test.tsx +++ b/plugins/catalog-react/src/alpha/blueprints/EntityContextMenuItemBlueprint.test.tsx @@ -48,25 +48,6 @@ describe('EntityContextMenuItemBlueprint', () => { }, ]; - const filterTestCases = [ - { - params: { filter: 'kind:component' }, - config: undefined, - }, - { - params: { filter: (e: Entity) => e.kind.toLowerCase() === 'component' }, - config: undefined, - }, - { - params: {}, - config: { filter: 'kind:component' }, - }, - { - params: {}, - config: { filter: { kind: 'component' } }, - }, - ]; - it.each(data)('should return an extension with sane defaults', params => { const extension = EntityContextMenuItemBlueprint.make({ name: 'test', @@ -230,72 +211,6 @@ describe('EntityContextMenuItemBlueprint', () => { `); }); - it.each(filterTestCases)( - 'should exclude items based on the filter', - async ({ params, config }) => { - const extension = EntityContextMenuItemBlueprint.make({ - name: 'test', - params: { - icon: Icon, - ...params, - useProps: () => ({ - title: 'Test', - onClick: () => {}, - }), - }, - }); - - renderInTestApp( - -
    {createExtensionTester(extension, { config }).reactElement()}
-
, - ); - - await waitFor(() => { - expect(screen.queryByText('Test')).not.toBeInTheDocument(); - }); - }, - ); - - it.each(filterTestCases)( - 'should include items based on the filter', - async ({ params, config }) => { - const extension = EntityContextMenuItemBlueprint.make({ - name: 'test', - params: { - icon: Icon, - ...params, - useProps: () => ({ - title: 'Test', - onClick: () => {}, - }), - }, - }); - - renderInTestApp( - -
    {createExtensionTester(extension, { config }).reactElement()}
-
, - ); - - await waitFor(() => { - expect(screen.getByText('Test')).toBeInTheDocument(); - }); - }, - ); - it('should render a menu item', async () => { const extension = EntityContextMenuItemBlueprint.make({ name: 'test',