Skip to content

Commit

Permalink
Merge pull request #838 from include-dcc/cypress/sjip-1196
Browse files Browse the repository at this point in the history
feat: SJIP-1196 Adjust cypress configs
  • Loading branch information
kstonge authored Jan 21, 2025
2 parents 0a2e8ad + 6e02ae2 commit 7f23116
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 13 deletions.
4 changes: 3 additions & 1 deletion cypress.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@ const { strDate, strTime } = getDateTime();

const getName = (url = '', parallel = '') => {
if (url.includes('netlify')) {
return url.replace('https://', '').split('.')[0].split('-')[2]+'/'+parallel;
return (
url.replace('https://', '').split('.')[0].split('-')[2]+'/'+parallel
);
} else {
return 'QA/'+parallel;
}
Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/Consultation/TableauStudies.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,9 @@ describe('Page des études - Consultation du tableau', () => {

it('Valider les fonctionnalités du tableau - Tri Name', () => {
cy.sortTableAndIntercept('Name', 1);
cy.validateTableFirstRow('Alzheimer Biomarker Consortium - Down Syndrome', 2);
cy.validateTableFirstRow(/^A/, 2);
cy.sortTableAndIntercept('Name', 1);
cy.validateTableFirstRow('The epidemiology of transient leukemia in newborns with Down syndrome', 2);
cy.validateTableFirstRow(/^(?!A)/, 2);
});

it('Valider les fonctionnalités du tableau - Tri dbGaP', () => {
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/Facettes/PageStudies.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ describe('Page des études - Filtrer avec les facettes', () => {
cy.validateFacetRank(5, 'Data Source');
});

it('Design - Longitudinal [SJIP-1165]', () => {
it('Design - Longitudinal', () => {
cy.validateFacetFilter('Design', 'Longitudinal', 'Longitudinal', /\d{1} Result/, false);
cy.validateFacetRank(6, 'Design');
});
Expand Down
8 changes: 4 additions & 4 deletions cypress/e2e/Requetes/ValidationParticipants.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ describe('Page Data Exploration - Requêtes', () => {
cy.get('[class*="QueryBar_queryBarWrapper"]').eq(3).clickAndWait();
cy.wait('@getPOSTgraphql');

cy.validateTotalSelectedQuery(/(4,732|4,738|4,7434,751|4,756|4,927)/);
cy.validateTableResultsCount(/(4,732|4,738|4,7434,751|4,756|4,927)/);
cy.validateTotalSelectedQuery(/(4,732|4,733|4,738|4,743|4,751|4,756|4,927)/);
cy.validateTableResultsCount(/(4,732|4,733|4,738|4,743|4,751|4,756|4,927)/);
});

it('Validation Facette standard (All of)', () => {
Expand All @@ -62,8 +62,8 @@ describe('Page Data Exploration - Requêtes', () => {
cy.get('[class*="QueryBar_queryBarWrapper"]').eq(5).clickAndWait();
cy.wait('@getPOSTgraphql');

cy.validateTotalSelectedQuery(/(4,629|4,656|4,675|4,680|4,688|4,693|4,715|8,632)/);
cy.validateTableResultsCount(/(4,629|4,656|4,675|4,680|4,688|4,693|4,715|8,632)/);
cy.validateTotalSelectedQuery(/(4,629|4,656|4,675|4,680|4,688|4,693|4,713|4,715|8,632)/);
cy.validateTableResultsCount(/(4,629|4,656|4,675|4,680|4,688|4,693|4,713|4,715|8,632)/);
});

it('Validation Facette standard (None of) ET Facette numérique', () => {
Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/Telechargement/ClinicalDataPageParticipant.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ describe('Page d\'un participant - Télécharger le clinical data', () => {
cy.validateFileName(`include_clinicalData_${strDate.slice(0, 4)}${strDate.slice(4, 6)}${strDate.slice(6, 8)}T*.xlsx`);
});

it('Valider le contenu du fichier [SJIP-1164]', () => {
it('Valider le contenu du fichier', () => {
cy.validateXlsxFileContent('DownloadClinicalData.json');
});
});
Expand All @@ -37,7 +37,7 @@ describe('Page d\'un participant - Télécharger le clinical data (family)', ()
cy.validateFileName(`include_familyClinicalData_${strDate.slice(0, 4)}${strDate.slice(4, 6)}${strDate.slice(6, 8)}T*.xlsx`);
});

it('Valider le contenu du fichier [SJIP-1164]', () => {
it('Valider le contenu du fichier', () => {
cy.validateXlsxFileContent('DownloadClinicalDataFamily.json');
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ describe('Page Data Exploration (Participants) - Télécharger le clinical data'
cy.validateFileName(`include_clinicalData_${strDate.slice(0, 4)}${strDate.slice(4, 6)}${strDate.slice(6, 8)}T*.xlsx`);
});

it('Valider le contenu du fichier [SJIP-1164]', () => {
it('Valider le contenu du fichier', () => {
cy.validateXlsxFileContent('DownloadClinicalData.json');
});
});
Expand All @@ -38,7 +38,7 @@ describe('Page Data Exploration (Participants) - Télécharger le clinical data
cy.validateFileName(`include_familyClinicalData_${strDate.slice(0, 4)}${strDate.slice(4, 6)}${strDate.slice(6, 8)}T*.xlsx`);
});

it('Valider le contenu du fichier [SJIP-1164]', () => {
it('Valider le contenu du fichier', () => {
cy.validateXlsxFileContent('DownloadClinicalDataFamily.json');
});
});
2 changes: 1 addition & 1 deletion cypress/fixtures/ExportTableauFamilyPageParticipant.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
"Family Relationship",
"Down Syndrome Status"],
"content": ["pt-v66khv4x",
"father",
"ather",
"D21"]
}

0 comments on commit 7f23116

Please sign in to comment.