diff --git a/cypress/e2e/report.cy.ts b/cypress/e2e/report.cy.ts index c7824b91..8a4bef4d 100644 --- a/cypress/e2e/report.cy.ts +++ b/cypress/e2e/report.cy.ts @@ -24,11 +24,8 @@ describe('Feature Report', () => { it('can\'t report with an empty reason', () => { loginAsVoluntary(); accessToReportModal(); - cy.get('p-button').contains('Envoyer') - .click(); - cy.get('app-textarea-field p') - .contains('Ce champ est requis') - .should('be.visible'); + cy.get('p-button[label="Envoyer"] button') + .should('be.disabled'); cy.get('body').find('.p-dialog-mask') .click({ force: true }); logout(); diff --git a/cypress/fixtures/common/userByToken.json b/cypress/fixtures/common/userByToken.json new file mode 100644 index 00000000..fd542811 --- /dev/null +++ b/cypress/fixtures/common/userByToken.json @@ -0,0 +1,5 @@ +{ + "user": { + + } +} \ No newline at end of file diff --git a/cypress/support/e2e.ts b/cypress/support/e2e.ts index ed8ab040..794b82a7 100644 --- a/cypress/support/e2e.ts +++ b/cypress/support/e2e.ts @@ -1,5 +1,6 @@ beforeEach(() => { // the home page's necessary mocks + cy.intercept('GET', '/auth/token', {fixture: null}).as('getUserByToken'); cy.intercept('GET', '/activities/future', { fixture: '/common/activities.json' }).as('getActivities'); cy.intercept('GET', '/themes', { fixture: '/common/themes.json' }).as('getThemes'); cy.intercept('GET', 'https://api.maptiler.com/maps/**', { statusCode: 200, body: {} }).as('mapTiler'); diff --git a/src/app/features/activity/pages/activities-home/activities-home.component.scss b/src/app/features/activity/pages/activities-home/activities-home.component.scss index 3f5f18d2..9b77af32 100644 --- a/src/app/features/activity/pages/activities-home/activities-home.component.scss +++ b/src/app/features/activity/pages/activities-home/activities-home.component.scss @@ -121,21 +121,6 @@ background-color: var(--primary-dark-color); } - .btn-reset { - margin-top: 1rem; - padding: 0.5rem 1rem; - border: none; - border-radius: 6px; - background-color: #007ad9; - color: #fff; - cursor: pointer; - font-weight: 500; - } - - .btn-reset:hover { - background-color: #005fa3; - } - i { margin-right: 8px; } diff --git a/src/app/features/report/components/report-modal/report-modal.component.html b/src/app/features/report/components/report-modal/report-modal.component.html index a44f3ec6..c496eaab 100644 --- a/src/app/features/report/components/report-modal/report-modal.component.html +++ b/src/app/features/report/components/report-modal/report-modal.component.html @@ -20,7 +20,7 @@

Commentaire libre