From c36a90a149a828aa0601e128edf4169cf01e457d Mon Sep 17 00:00:00 2001 From: Ramon Wenger Date: Thu, 7 Oct 2021 17:27:20 +0200 Subject: [PATCH] Update frontend test --- .../frontend/portfolio/project-page.spec.js | 12 +++++++----- client/src/consts/strings.consts.js | 2 +- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/client/cypress/integration/frontend/portfolio/project-page.spec.js b/client/cypress/integration/frontend/portfolio/project-page.spec.js index 7bc161fa..3383f46b 100644 --- a/client/cypress/integration/frontend/portfolio/project-page.spec.js +++ b/client/cypress/integration/frontend/portfolio/project-page.spec.js @@ -1,6 +1,9 @@ import {PROJECT_ENTRY_TEMPLATE} from '../../../../src/consts/strings.consts'; describe('Project Page', () => { + const created = '2021-06-01T11:49:00+00:00'; + const createdLater = '2021-06-01T12:49:00+00:00'; + const operations = { MeQuery: { me: { @@ -49,7 +52,7 @@ describe('Project Page', () => { id: 'UHJvamVjdEVudHJ5Tm9kZTo2NQ==', description: 'Aktivität:\nKill Thanos\n\n\nReflexion:\nHe sucks\n\n\nNächste Schritte:\nGo for the head', documentUrl: '', - created: '2020-06-01T13:49:31.262510+00:00', + created, }, ], }, @@ -57,10 +60,9 @@ describe('Project Page', () => { AddProjectEntry: variables => ({ addProjectEntry: { projectEntry: Object.assign({}, variables.input.projectEntry, { - created: '2021-01-20T15:26:58.722773+00:00', + created: createdLater }), - errors: null, - __typename: 'AddProjectEntryPayload', + errors: null }, }), UpdateProjectEntry: variables => ({ @@ -109,7 +111,7 @@ describe('Project Page', () => { cy.getByDataCy('modal-save-button').click(); cy.get('.project-entry:last-of-type').within(() => { - cy.get('.project-entry__paragraph:first-of-type').contains('Join the Guardians'); + cy.get('.project-entry__paragraph:first-of-type').contains('Schwierigkeiten'); }); }); diff --git a/client/src/consts/strings.consts.js b/client/src/consts/strings.consts.js index f47b4cec..f641ea17 100644 --- a/client/src/consts/strings.consts.js +++ b/client/src/consts/strings.consts.js @@ -3,7 +3,7 @@ Was? Wie? Welche Mittel? Reflexion: -Was ging gut? Was hatte ich für Schweirigkeiten? Was habe ich gelernt? +Was ging gut? Was hatte ich für Schwierigkeiten? Was habe ich gelernt? Nächste Schritte: