diff --git a/src/Components/UpgradeRisksTable/ClusterOperatorsList.js b/src/Components/UpgradeRisksTable/ClusterOperatorsList.js index 5b535806..303d5af3 100644 --- a/src/Components/UpgradeRisksTable/ClusterOperatorsList.js +++ b/src/Components/UpgradeRisksTable/ClusterOperatorsList.js @@ -12,13 +12,6 @@ import { useGetUpgradeRisksQuery } from '../../Services/SmartProxy'; import { Flex, Icon } from '@patternfly/react-core'; import ExclamationTriangleIcon from '@patternfly/react-icons/dist/esm/icons/exclamation-triangle-icon'; -export const CLUSTER_OPERATOR_LABEL = { - degraded: 'Degraded', - failing: 'Failing', - available: 'Not Available', - upgradeable: 'Not Upgradeable', -}; - const ClusterOperatorsList = () => { const { clusterId } = useParams(); const { data } = useGetUpgradeRisksQuery({ id: clusterId }); @@ -49,7 +42,7 @@ const ClusterOperatorsList = () => { - {CLUSTER_OPERATOR_LABEL[condition]} + {condition} {reason || '-'} diff --git a/src/Components/UpgradeRisksTable/UpgradeRisksTable.cy.js b/src/Components/UpgradeRisksTable/UpgradeRisksTable.cy.js index 6a9678fa..3cd86d11 100644 --- a/src/Components/UpgradeRisksTable/UpgradeRisksTable.cy.js +++ b/src/Components/UpgradeRisksTable/UpgradeRisksTable.cy.js @@ -20,13 +20,6 @@ const SEVERITY_ICON_CLASS_MAPPING = { info: 'info', }; -export const CLUSTER_OPERATOR_LABEL_MAPPING = { - degraded: 'Degraded', - failing: 'Failing', - available: 'Not Available', - upgradeable: 'Not Upgradeable', -}; - const CLUSTER_ID = '41c30565-b4c9-49f2-a4ce-3277ad22b258'; const mount = (initialEntries = [`/clusters/${CLUSTER_ID}`]) => { @@ -130,10 +123,7 @@ describe('successful with some risks', () => { .should('have.text', condition.name); cy.get($row) .find('.operators__status') - .should( - 'contain.text', - CLUSTER_OPERATOR_LABEL_MAPPING[condition.condition] - ); + .should('contain.text', condition.condition); cy.get($row) .find('.operators__status .pf-c-icon__content') .should('have.class', `pf-m-warning`);