diff --git a/backend/src/main/resources/application-staging.properties b/backend/src/main/resources/application-staging.properties index effd67d65a..38e4a47571 100644 --- a/backend/src/main/resources/application-staging.properties +++ b/backend/src/main/resources/application-staging.properties @@ -1,5 +1,7 @@ # logging level for staging -logging.level.org.springframework=debug +logging.level.ch.puzzle.okr=DEBUG +#logging.level.org.flywaydb.core=DEBUG + connect.src=http://localhost:8544 http://localhost:8545 diff --git a/frontend/cypress/e2e/checkIn.cy.ts b/frontend/cypress/e2e/checkIn.cy.ts index 45728dedc0..70c2c17a38 100644 --- a/frontend/cypress/e2e/checkIn.cy.ts +++ b/frontend/cypress/e2e/checkIn.cy.ts @@ -163,12 +163,12 @@ describe('OKR Check-in e2e tests', () => { cy.contains(getCurrentDate()); cy.contains('Wert: 30%'); cy.contains('Wert: 50%'); - cy.contains('Confidence: 5 / 10'); - cy.contains('Confidence: 6 / 10'); - cy.contains('Veränderungen: We bought a new house'); - cy.contains('Veränderungen: This was a good idea'); - cy.contains('Massnahmen: We have to buy more PCs'); - cy.contains('Massnahmen: Will be difficult'); + checkForAttribute('Confidence:', '5 / 10'); + checkForAttribute('Confidence:', '6 / 10'); + checkForAttribute('Veränderungen:', 'We bought a new house'); + checkForAttribute('Veränderungen:', 'This was a good idea'); + checkForAttribute('Massnahmen:', 'We have to buy more PCs'); + checkForAttribute('Massnahmen:', 'Will be difficult'); cy.contains('Schliessen'); }); @@ -312,7 +312,7 @@ describe('OKR Check-in e2e tests', () => { cy.wait('@getKeyResultsAfterSave'); cy.getByTestId('add-check-in').first().click(); - cy.get('#old-value label + div').contains('10 %'); + cy.contains('Letzter Wert').siblings('div').contains('10 %'); }); }); }); @@ -359,3 +359,7 @@ function getCurrentDate() { return dd_str + '.' + mm_str + '.' + yyyy; } + +function checkForAttribute(title: string, value: string) { + cy.get('mat-dialog-container').contains(value).parent().should('contain', title); +} diff --git a/frontend/cypress/e2e/duplicated-scoring.cy.ts b/frontend/cypress/e2e/duplicated-scoring.cy.ts index d1152ced59..6a87dbd243 100644 --- a/frontend/cypress/e2e/duplicated-scoring.cy.ts +++ b/frontend/cypress/e2e/duplicated-scoring.cy.ts @@ -9,7 +9,10 @@ describe('e2e test for scoring adjustment on objective duplicate', () => { }); it('Create ordinal checkin and validate value of scoring component', () => { + cy.intercept('POST', '**/keyresults').as('createKeyresult'); cy.createOrdinalKeyresult('stretch keyresult for testing', null); + cy.wait('@createKeyresult'); + cy.contains('stretch keyresult for testing'); cy.getByTestId('keyresult').get(':contains("stretch keyresult for testing")').last().click(); cy.getByTestId('add-check-in').click(); cy.getByTestId(`stretch-radio`).click(); @@ -26,7 +29,7 @@ describe('e2e test for scoring adjustment on objective duplicate', () => { cy.visit('/?quarter=3'); let scoringBlock1 = cy - .getByTestId('objective') + .get('.objective:contains("A duplicated Objective for this tool")') .first() .getByTestId('key-result') .first() diff --git a/frontend/cypress/e2e/keyresult.cy.ts b/frontend/cypress/e2e/keyresult.cy.ts index f7f9ef7b67..aaa5d3b709 100644 --- a/frontend/cypress/e2e/keyresult.cy.ts +++ b/frontend/cypress/e2e/keyresult.cy.ts @@ -294,7 +294,7 @@ describe('OKR Overview', () => { cy.getByTestId('edit-keyResult').click(); cy.getByTestId('delete-keyResult').click(); - cy.getByTestId('confirmYes').click(); + cy.getByTestId('confirm-yes').click(); cy.contains('Puzzle ITC'); cy.get('A keyresult to delete').should('not.exist'); diff --git a/frontend/cypress/e2e/objective.cy.ts b/frontend/cypress/e2e/objective.cy.ts index 758d7687a3..83eb98496e 100644 --- a/frontend/cypress/e2e/objective.cy.ts +++ b/frontend/cypress/e2e/objective.cy.ts @@ -30,7 +30,7 @@ describe('OKR Objective e2e tests', () => { .click(); cy.contains('Objective veröffentlichen'); cy.contains('Soll dieses Objective veröffentlicht werden?'); - cy.getByTestId('confirmYes').click(); + cy.getByTestId('confirm-yes').click(); cy.getByTestId('objective') .filter(':contains(A objective in state draft)') .last() diff --git a/frontend/cypress/e2e/tab.cy.ts b/frontend/cypress/e2e/tab.cy.ts index 4d1cdd714b..ee8143f4eb 100644 --- a/frontend/cypress/e2e/tab.cy.ts +++ b/frontend/cypress/e2e/tab.cy.ts @@ -416,7 +416,7 @@ describe('Tab workflow tests', () => { cy.tabForwardUntil('[data-testId="add-action-plan-line"]'); cy.tabBackward(); cy.realPress('Enter'); - cy.tabForwardUntil('[data-testId="confirmYes"]'); + cy.tabForwardUntil('[data-testId="confirm-yes"]'); cy.realPress('Enter'); cy.tabForward(); cy.tabForwardUntil('[data-testId="submit"]'); diff --git a/frontend/cypress/e2e/teammanagement.cy.ts b/frontend/cypress/e2e/teammanagement.cy.ts index d89d8b06e1..6edf0db28e 100644 --- a/frontend/cypress/e2e/teammanagement.cy.ts +++ b/frontend/cypress/e2e/teammanagement.cy.ts @@ -44,8 +44,8 @@ describe('Team management tests', () => { cy.getByTestId('remove-from-member-list').click(); // dialog - cy.contains(`Jaya Norris wirklich aus Team ${teamName} entfernen?`); - cy.getByTestId('cancelDialog-confirm').click(); + cy.contains(`Möchtest du Jaya Norris wirklich aus dem Team '${teamName}' entfernen?`); + cy.getByTestId('confirm-yes').click(); cy.wait('@removeUser'); @@ -60,8 +60,8 @@ describe('Team management tests', () => { cy.getByTestId('remove-from-member-list').click(); // cancel dialog - cy.contains(`Jaya Norris wirklich aus Team ${teamName} entfernen?`); - cy.getByTestId('cancelDialog-cancel').click(); + cy.contains(`Möchtest du Jaya Norris wirklich aus dem Team '${teamName}' entfernen?`); + cy.getByTestId('confirm-no').click(); cy.get('@removeUser.all').then((interceptions) => { expect(interceptions).to.have.length(0); @@ -96,14 +96,18 @@ describe('Team management tests', () => { cy.getByTestId('teamDeleteButton').click(); // cancel dialog => cancel - cy.contains(`${teamName} wirklich löschen?`); - cy.getByTestId('cancelDialog-cancel').click(); + cy.contains( + `Möchtest du das Team '${teamName}' wirklich löschen? Zugehörige Objectives werden dadurch in allen Quartalen ebenfalls gelöscht!`, + ); + cy.getByTestId('confirm-no').click(); // try again and confirm dialog cy.getByTestId('teamMoreButton').click(); cy.getByTestId('teamDeleteButton').click(); - cy.contains(`${teamName} wirklich löschen?`); - cy.getByTestId('cancelDialog-confirm').click(); + cy.contains( + `Möchtest du das Team '${teamName}' wirklich löschen? Zugehörige Objectives werden dadurch in allen Quartalen ebenfalls gelöscht!`, + ); + cy.getByTestId('confirm-yes').click(); cy.wait(['@saveTeam', '@getUsers']); @@ -149,6 +153,10 @@ describe('Team management tests', () => { const firstNameStefan = uniqueSuffix('Stefan'); cy.getByTestId('invite-member').click(); + cy.wait(1000); // wait for dialog to open + cy.tabForward(); + cy.contains('Members registrieren'); + fillOutNewUser(firstNameClaudia, 'Meier', mailUserClaudia); cy.tabForward(); cy.tabForward(); @@ -305,7 +313,7 @@ describe('Team management tests', () => { // add findus peterson cy.getByTestId('search-member-to-add').click().type('Find', { delay: 1 }); - cy.get(matOption).contains('Findus Peterson').click(); + cy.contains(matOption, 'Findus Peterson').click(); // add robin papierer cy.getByTestId('search-member-to-add').click(); @@ -336,6 +344,7 @@ describe('Team management tests', () => { return; } $row.find(`[data-testId='edit-role']`).click(); + cy.wait(500); // wait for dialog to open }) .then(() => { cy.getByTestId('select-team-role').click(); @@ -356,7 +365,7 @@ describe('Team management tests', () => { it('should remove BBT membership of findus', () => { navigateToUser('Findus Peterson'); cy.getByTestId('delete-team-member').click(); - cy.getByTestId('cancelDialog-confirm').click(); + cy.getByTestId('confirm-yes').click(); cy.get('app-member-detail').contains('/BBT').should('not.exist'); }); @@ -365,12 +374,12 @@ describe('Team management tests', () => { navigateToUser(nameEsha); cy.getByTestId('delete-team-member').eq(0).click(); - cy.getByTestId('cancelDialog-confirm').click(); + cy.getByTestId('confirm-yes').click(); cy.wait('@removeUser'); cy.getByTestId('delete-team-member').eq(0).click(); - cy.getByTestId('cancelDialog-confirm').click(); + cy.getByTestId('confirm-yes').click(); cy.get('app-member-detail').should('not.contain', '/BBT').and('not.contain', 'LoremIpsum'); }); diff --git a/frontend/cypress/support/commands.ts b/frontend/cypress/support/commands.ts index 1fa1df2314..30e6b962c6 100644 --- a/frontend/cypress/support/commands.ts +++ b/frontend/cypress/support/commands.ts @@ -1,6 +1,7 @@ import { validateScoring } from './scoringSupport'; Cypress.Commands.add('loginAsUser', (user: any) => { + cy.viewport(1920, 1080); loginWithCredentials(user.username, user.password); overviewIsLoaded(); }); diff --git a/frontend/src/app/app.component.scss b/frontend/src/app/app.component.scss index 97a874648e..8ba091ef8b 100644 --- a/frontend/src/app/app.component.scss +++ b/frontend/src/app/app.component.scss @@ -1,12 +1,3 @@ -.okr-label { - margin-left: 35px; -} - -.overview-item { - margin-right: 20px; - margin-left: 50px; -} - app-application-top-bar { z-index: 1001; position: relative; diff --git a/frontend/src/app/app.module.ts b/frontend/src/app/app.module.ts index 58fa564e59..6e3150d3c1 100644 --- a/frontend/src/app/app.module.ts +++ b/frontend/src/app/app.module.ts @@ -166,9 +166,9 @@ export const MY_FORMATS = { MatChipsModule, CdkDropList, CdkDrag, - SharedModule, A11yModule, CdkDragHandle, + SharedModule, ], providers: [ { diff --git a/frontend/src/app/callback/callback.component.html b/frontend/src/app/callback/callback.component.html deleted file mode 100644 index 9a5f2cf345..0000000000 --- a/frontend/src/app/callback/callback.component.html +++ /dev/null @@ -1 +0,0 @@ -
You are getting forwarded!
diff --git a/frontend/src/app/callback/callback.component.ts b/frontend/src/app/callback/callback.component.ts deleted file mode 100644 index ac042fdc53..0000000000 --- a/frontend/src/app/callback/callback.component.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { Component } from '@angular/core'; - -@Component({ - selector: 'app-callback', - templateUrl: './callback.component.html', - styleUrl: './callback.component.css', -}) -export class CallbackComponent {} diff --git a/frontend/src/app/components/action-plan/action-plan.component.html b/frontend/src/app/components/action-plan/action-plan.component.html index b056643283..4d7b642f9e 100644 --- a/frontend/src/app/components/action-plan/action-plan.component.html +++ b/frontend/src/app/components/action-plan/action-plan.component.html @@ -1,11 +1,11 @@ -