Skip to content

Commit

Permalink
fix(AffectedClustersTable): replace impacted label OCPADVISOR-52
Browse files Browse the repository at this point in the history
  • Loading branch information
tompsota authored and gkarat committed Sep 22, 2022
1 parent 254855b commit 99bdd6e
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion compiled-lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"impact": "Impact",
"impactDescription": "The impact of the problem would be {level} if it occurred.",
"impactLevel": "{level} impact",
"impacted": "Impacted",
"impacted": "First impacted",
"important": "Important",
"insightsHeader": "Advisor",
"justificationNote": "Justification note",
Expand Down
2 changes: 1 addition & 1 deletion src/AppConstants.js
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ export const AFFECTED_CLUSTERS_IMPACTED_CELL = 4;
export const AFFECTED_CLUSTERS_COLUMNS = [
{
title: intl.formatMessage(messages.name),
transforms: [sortable, cellWidth(60)],
transforms: [sortable, cellWidth(50)],
},
{
title: intl.formatMessage(messages.version),
Expand Down
12 changes: 6 additions & 6 deletions src/Components/AffectedClustersTable/AffectedClustersTable.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,9 @@ describe('test data', () => {
expect(filterData({ version: [''] })).to.have.length.gte(1);
});
it('has at least one enabled cluster with missing impacted date', () => {
expect(
values.filter((v) => !Object.hasOwn(v, 'impacted')).length
).to.be.gte(1);
expect(values.filter((v) => v['impacted'] === undefined).length).to.be.gte(
1
);
});
it('has at least one enabled cluster with empty impacted date', () => {
expect(values.filter((v) => v['impacted'] === '').length).to.be.gte(1);
Expand Down Expand Up @@ -636,12 +636,12 @@ describe('non-empty successful affected clusters table', () => {

it('missing impacted date shown as Not available', () => {
filterApply({
name: values.filter((v) => !Object.hasOwn(v, 'impacted'))[0].name,
name: values.filter((v) => v['impacted'] === undefined)[0].name,
});
cy.get('[data-label="Impacted"]').should('contain', 'Not available');
cy.get('[data-label="First impacted"]').should('contain', 'Not available');
removeAllChips();
filterApply({ name: values.filter((v) => v['impacted'] === '')[0].name });
cy.get('[data-label="Impacted"]').should('contain', 'Not available');
cy.get('[data-label="First impacted"]').should('contain', 'Not available');
});
});

Expand Down
2 changes: 1 addition & 1 deletion src/Messages.js
Original file line number Diff line number Diff line change
Expand Up @@ -607,6 +607,6 @@ export default defineMessages({
},
impacted: {
id: 'impacted',
defaultMessage: 'Impacted',
defaultMessage: 'First impacted',
},
});

0 comments on commit 99bdd6e

Please sign in to comment.