Skip to content

Commit

Permalink
fixed tests
Browse files Browse the repository at this point in the history
  • Loading branch information
IrisOlfermann committed Jan 14, 2025
1 parent b685a4a commit 9cdbec3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/Mealz/MealBundle/Tests/Controller/EventControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ public function testJoin(): void
$partRepo = self::getContainer()->get(ParticipantRepositoryInterface::class);

/** @var Participant $part */
$part = $partRepo->findOneBy(['event' => $eventPart->getId()]);
$part = $partRepo->findOneBy(['event_participation' => $eventPart->getId()]);
$this->assertNotNull($part);

$this->assertEquals(self::USER_KITCHEN_STAFF, $part->getProfile()->getUsername());
Expand Down Expand Up @@ -194,7 +194,7 @@ public function testLeave(): void
$partRepo = self::getContainer()->get(ParticipantRepositoryInterface::class);

/** @var Participant $part */
$part = $partRepo->findOneBy(['event' => $eventPart->getId()]);
$part = $partRepo->findOneBy(['event_participation' => $eventPart->getId()]);
$this->assertNull($part);
}

Expand Down
10 changes: 5 additions & 5 deletions tests/e2e/cypress/e2e/Menu.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ describe('Test Weeks View', () => {
cy.wait(['@getDishesCount', '@getCategories', '@getDishes', '@getEvents', '@getLockdates']);

cy.url().should('include', '/menu');
cy.get('h2').should('contain', 'Woche bearbeiten #28 (08.07. - 12.07.)');
cy.get('h2').should('contain', 'Woche bearbeiten #28 (07.07. - 11.07.)');

// change input
cy.get('input')
Expand All @@ -41,7 +41,7 @@ describe('Test Weeks View', () => {
.parent().parent()
.find('li').contains('Lammhaxxe in Biersoße mit Klößen')
.click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (08.07. - 12.07.)').click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (07.07. - 11.07.)').click();

// change event
cy.get('input')
Expand Down Expand Up @@ -93,7 +93,7 @@ describe('Test Weeks View', () => {
.clear()
.type('17');
cy.get('span').contains('Limit').parent().find('svg').click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (08.07. - 12.07.)').click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (07.07. - 11.07.)').click();

// change lock date
cy.get('input')
Expand All @@ -112,7 +112,7 @@ describe('Test Weeks View', () => {
.contains(new RegExp(/^7$/))
.click()
cy.get('span').contains('Sperren').parent().find('svg').click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (08.07. - 12.07.)').click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (07.07. - 11.07.)').click();

// change input
cy.get('input')
Expand All @@ -130,7 +130,7 @@ describe('Test Weeks View', () => {
.click();
cy.get('button').contains('Variation').click();
cy.get('span').contains('Innards DE #v1').click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (08.07. - 12.07.)').click();
cy.get('h2').should('contain', 'Woche bearbeiten #28 (07.07. - 11.07.)').click();

cy.contains('input', 'Speichern').click();

Expand Down

0 comments on commit 9cdbec3

Please sign in to comment.