From 6533969392b83a610a46acf32e1663f2e0c0426f Mon Sep 17 00:00:00 2001 From: Abderrahmane Smimite Date: Sun, 14 Apr 2024 14:25:05 +0200 Subject: [PATCH 1/6] Rename Compliance Assessment to Audit - display only --- frontend/messages/en.json | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/frontend/messages/en.json b/frontend/messages/en.json index 198a3aef7..d0b3d8a51 100644 --- a/frontend/messages/en.json +++ b/frontend/messages/en.json @@ -9,7 +9,7 @@ "addRiskAssessment": "Add risk assessment", "addRiskScenario": "Add risk scenario", "addRiskAcceptance": "Add risk acceptance", - "addComplianceAssessment": "Add compliance assessment", + "addComplianceAssessment": "Start Audit", "addEvidence": "Add evidence", "addDomain": "Add domain", "addProject": "Add project", @@ -22,7 +22,7 @@ "associatedRiskAssessments": "Associated risk assessments", "associatedRiskScenarios": "Associated risk scenarios", "associatedRiskAcceptances": "Associated risk acceptances", - "associatedComplianceAssessments": "Associated compliance assessments", + "associatedComplianceAssessments": "Associated Audits", "associatedEvidences": "Associated evidences", "associatedDomains": "Associated domains", "associatedProjects": "Associated projects", @@ -52,8 +52,8 @@ "riskScenario": "Risk scenario", "riskAcceptances": "Risk acceptances", "riskAcceptance": "Risk acceptance", - "complianceAssessments": "Compliance assessments", - "complianceAssessment": "Compliance assessment", + "complianceAssessments": "Audits", + "complianceAssessment": "Audit", "evidences": "Evidences", "evidence": "Evidence", "frameworks": "Frameworks", @@ -482,7 +482,7 @@ "usedRiskMatrices": "Used risk matrices", "usedFrameworks": "Used frameworks", "riskAssessmentsStatus": "Risk assessments status", - "complianceAssessmentsStatus": "Compliance assessments status", + "complianceAssessmentsStatus": "Audits status", "noDescription": "No description", "noExistingControls": "No existing controls", "noJustification": "No justification", From 93bec2f48f00eb8189a4653e15633acc436cf4a5 Mon Sep 17 00:00:00 2001 From: Mohamed-Hacene <90701924+Mohamed-Hacene@users.noreply.github.com> Date: Mon, 15 Apr 2024 21:02:48 +0200 Subject: [PATCH 2/6] =?UTF-8?q?Fink=20=F0=9F=90=A6:=20update=20translation?= =?UTF-8?q?s?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/messages/en.json | 2 +- frontend/messages/fr.json | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/frontend/messages/en.json b/frontend/messages/en.json index d0b3d8a51..5979eecfb 100644 --- a/frontend/messages/en.json +++ b/frontend/messages/en.json @@ -367,7 +367,7 @@ "extraLarge": "Extra-large", "rid": "RID", "scope": "Scope", - "auditor": "Auditor", + "auditor": "Reader", "lastUpdate": "Last update", "riskScenarioAssetHelpText": "Assets impacted by this risk scenario", "riskScenarioMeasureHelpText": "The existing applied controls to manage this risk", diff --git a/frontend/messages/fr.json b/frontend/messages/fr.json index 20e596122..cd9e629d8 100644 --- a/frontend/messages/fr.json +++ b/frontend/messages/fr.json @@ -9,7 +9,7 @@ "addRiskAssessment": "Ajouter une évaluation de risque", "addRiskScenario": "Ajouter un scénario de risque", "addRiskAcceptance": "Ajouter une acceptation de risque", - "addComplianceAssessment": "Ajouter une évaluation de conformité", + "addComplianceAssessment": "Démarrer l'audit", "addEvidence": "Ajouter une preuve", "addDomain": "Ajouter un domaine", "addProject": "Ajouter un projet", @@ -22,7 +22,7 @@ "associatedRiskAssessments": "Évaluations de risque associées", "associatedRiskScenarios": "Scénarios de risque associés", "associatedRiskAcceptances": "Acceptations de risque associées", - "associatedComplianceAssessments": "Évaluations de conformité associées", + "associatedComplianceAssessments": "Audits associés", "associatedEvidences": "Preuves associées", "associatedDomains": "Domaines associés", "associatedProjects": "Projets associés", @@ -52,8 +52,8 @@ "riskScenario": "Scénario de risque", "riskAcceptances": "Acceptations de risque", "riskAcceptance": "Acceptation de risque", - "complianceAssessments": "Évaluations de conformité", - "complianceAssessment": "Évaluation de conformité", + "complianceAssessments": "Audits", + "complianceAssessment": "Audit", "evidences": "Preuves", "evidence": "Preuve", "frameworks": "Cadres de référence", @@ -367,7 +367,7 @@ "extraLarge": "Très grand", "rid": "RID", "scope": "Périmètre", - "auditor": "Auditeur", + "auditor": "Lecteur", "lastUpdate": "Dernière mise à jour", "riskScenarioAssetHelpText": "Biens sensibles impactés par ce scénario de risque", "riskScenarioMeasureHelpText": "Les mesures appliquées existantes pour gérer ce risque", @@ -482,7 +482,7 @@ "usedRiskMatrices": "Matrices de risque utilisées", "usedFrameworks": "Cadres de référence utilisés", "riskAssessmentsStatus": "Statut des évaluations de risque", - "complianceAssessmentsStatus": "Statut des évaluations de conformité", + "complianceAssessmentsStatus": "Statut des audits", "noDescription": "Pas de description", "noExistingControls": "Aucune mesure existante", "noJustification": "Aucune justification", From 5e72f4b4bd2a7db5307a008205b3ef386323b5d0 Mon Sep 17 00:00:00 2001 From: Mohamed-Hacene Date: Mon, 15 Apr 2024 21:09:08 +0200 Subject: [PATCH 3/6] ci: replace compliance assessment by audit on UI --- frontend/tests/utils/test-utils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/tests/utils/test-utils.ts b/frontend/tests/utils/test-utils.ts index d33a189a5..21215cc26 100644 --- a/frontend/tests/utils/test-utils.ts +++ b/frontend/tests/utils/test-utils.ts @@ -95,7 +95,7 @@ export const test = base.extend({ }, complianceAssessmentsPage: async ({ page }, use) => { - const aPage = new PageContent(page, '/compliance-assessments', 'Compliance assessments', [ + const aPage = new PageContent(page, '/compliance-assessments', 'Audits', [ { name: 'name', type: type.TEXT }, { name: 'description', type: type.TEXT }, { name: 'project', type: type.SELECT_AUTOCOMPLETE }, @@ -469,7 +469,7 @@ export class TestContent { } }, complianceAssessmentsPage: { - displayName: 'Compliance assessments', + displayName: 'Audits', dependency: vars.framework, build: { name: vars.assessmentName, From 65a2d3ca37f32f64312d6230d886200dbfd383ef Mon Sep 17 00:00:00 2001 From: Mohamed-Hacene Date: Tue, 16 Apr 2024 17:08:51 +0200 Subject: [PATCH 4/6] chore: revert auditor/reader --- frontend/messages/en.json | 2 +- frontend/messages/fr.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/messages/en.json b/frontend/messages/en.json index 5979eecfb..d0b3d8a51 100644 --- a/frontend/messages/en.json +++ b/frontend/messages/en.json @@ -367,7 +367,7 @@ "extraLarge": "Extra-large", "rid": "RID", "scope": "Scope", - "auditor": "Reader", + "auditor": "Auditor", "lastUpdate": "Last update", "riskScenarioAssetHelpText": "Assets impacted by this risk scenario", "riskScenarioMeasureHelpText": "The existing applied controls to manage this risk", diff --git a/frontend/messages/fr.json b/frontend/messages/fr.json index cd9e629d8..70cedad06 100644 --- a/frontend/messages/fr.json +++ b/frontend/messages/fr.json @@ -367,7 +367,7 @@ "extraLarge": "Très grand", "rid": "RID", "scope": "Périmètre", - "auditor": "Lecteur", + "auditor": "Auditor", "lastUpdate": "Dernière mise à jour", "riskScenarioAssetHelpText": "Biens sensibles impactés par ce scénario de risque", "riskScenarioMeasureHelpText": "Les mesures appliquées existantes pour gérer ce risque", From c54ca92a202337d270ba28db1c13f5aae9454666 Mon Sep 17 00:00:00 2001 From: Mohamed-Hacene Date: Wed, 17 Apr 2024 17:40:56 +0200 Subject: [PATCH 5/6] ci: fix permissions test on audit --- frontend/tests/functional/user-permissions.test.ts | 8 ++++---- frontend/tests/utils/test-utils.ts | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/frontend/tests/functional/user-permissions.test.ts b/frontend/tests/functional/user-permissions.test.ts index 4773d575d..ef5d022b7 100644 --- a/frontend/tests/functional/user-permissions.test.ts +++ b/frontend/tests/functional/user-permissions.test.ts @@ -88,10 +88,10 @@ Object.entries(userGroups).forEach(([userGroup, userGroupData]) => { Object.entries(testObjectsData).forEach(([objectPage, objectData], index) => { test.describe(`${objectData.displayName.toLowerCase()} permissions`, () => { - const userCanView = userFromUserGroupHasPermission(userGroup, 'view', objectData.displayName); - const userCanCreate = userFromUserGroupHasPermission(userGroup, 'add', objectData.displayName); - const userCanUpdate = userFromUserGroupHasPermission(userGroup, 'change', objectData.displayName); - const userCanDelete = userFromUserGroupHasPermission(userGroup, 'delete', objectData.displayName); + const userCanView = userFromUserGroupHasPermission(userGroup, 'view', objectData.permName ?? objectData.displayName); + const userCanCreate = userFromUserGroupHasPermission(userGroup, 'add', objectData.permName ?? objectData.displayName); + const userCanUpdate = userFromUserGroupHasPermission(userGroup, 'change', objectData.permName ?? objectData.displayName); + const userCanDelete = userFromUserGroupHasPermission(userGroup, 'delete', objectData.permName ?? objectData.displayName); test.beforeAll(async ({pages}) => { await pages[objectPage].goto(); diff --git a/frontend/tests/utils/test-utils.ts b/frontend/tests/utils/test-utils.ts index 21215cc26..da682757b 100644 --- a/frontend/tests/utils/test-utils.ts +++ b/frontend/tests/utils/test-utils.ts @@ -384,6 +384,7 @@ export class TestContent { }, assetsPage: { displayName: 'Assets', + permName: 'complianceassessment', build: { name: vars.assetName, description: vars.description, From 0447f6ec177a3ec8b1af3ce2f5e0d03d93275af1 Mon Sep 17 00:00:00 2001 From: Mohamed-Hacene Date: Wed, 17 Apr 2024 17:45:20 +0200 Subject: [PATCH 6/6] chore: fix typo --- frontend/tests/utils/test-utils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/tests/utils/test-utils.ts b/frontend/tests/utils/test-utils.ts index da682757b..81799c90c 100644 --- a/frontend/tests/utils/test-utils.ts +++ b/frontend/tests/utils/test-utils.ts @@ -384,7 +384,6 @@ export class TestContent { }, assetsPage: { displayName: 'Assets', - permName: 'complianceassessment', build: { name: vars.assetName, description: vars.description, @@ -471,6 +470,7 @@ export class TestContent { }, complianceAssessmentsPage: { displayName: 'Audits', + permName: 'complianceassessment', dependency: vars.framework, build: { name: vars.assessmentName,