diff --git a/tests/php/integration/Db/AppointmentConfigMapperTest.php b/tests/php/integration/Db/AppointmentConfigMapperTest.php index 532e5c33f8..a040d00715 100644 --- a/tests/php/integration/Db/AppointmentConfigMapperTest.php +++ b/tests/php/integration/Db/AppointmentConfigMapperTest.php @@ -78,21 +78,14 @@ public function testFindById() { $id = $appointment->getId(); $appointment = $this->mapper->findById($id); - $this->assertObjectHasAttribute('token', $appointment); + $this->assertEquals('okens', $appointment->getToken()); - $this->assertObjectHasAttribute('name', $appointment); $this->assertEquals('Test 2', $appointment->getName()); - $this->assertObjectHasAttribute('description', $appointment); $this->assertEquals('Test Description', $appointment->getDescription()); - $this->assertObjectHasAttribute('increment', $appointment); $this->assertEquals(15 * 60, $appointment->getIncrement()); - $this->assertObjectHasAttribute('length', $appointment); $this->assertEquals(60 * 60, $appointment->getLength()); - $this->assertObjectHasAttribute('targetCalendarUri', $appointment); $this->assertEquals('testuri', $appointment->getTargetCalendarUri()); - $this->assertObjectHasAttribute('visibility', $appointment); $this->assertEquals(AppointmentConfig::VISIBILITY_PUBLIC, $appointment->getVisibility()); - $this->assertObjectHasAttribute('userId', $appointment); $this->assertEquals('testuser', $appointment->getUserId()); } @@ -114,21 +107,14 @@ public function testFindByToken() { $token = $appointment->getToken(); $appointment = $this->mapper->findByToken($token); - $this->assertObjectHasAttribute('token', $appointment); + $this->assertEquals('okensdsadsas', $appointment->getToken()); - $this->assertObjectHasAttribute('name', $appointment); $this->assertEquals('Test 2', $appointment->getName()); - $this->assertObjectHasAttribute('description', $appointment); $this->assertEquals('Test Description', $appointment->getDescription()); - $this->assertObjectHasAttribute('increment', $appointment); $this->assertEquals(15 * 60, $appointment->getIncrement()); - $this->assertObjectHasAttribute('length', $appointment); $this->assertEquals(60 * 60, $appointment->getLength()); - $this->assertObjectHasAttribute('targetCalendarUri', $appointment); $this->assertEquals('testuri', $appointment->getTargetCalendarUri()); - $this->assertObjectHasAttribute('visibility', $appointment); $this->assertEquals(AppointmentConfig::VISIBILITY_PUBLIC, $appointment->getVisibility()); - $this->assertObjectHasAttribute('userId', $appointment); $this->assertEquals('testuser', $appointment->getUserId()); } @@ -149,7 +135,6 @@ public function testFindAllForUser():void { $this->assertNotEmpty($appointments); foreach ($appointments as $appointment) { - $this->assertObjectHasAttribute('userId', $appointment); $this->assertEquals('testuser', $appointment->getUserId()); } } diff --git a/tests/php/integration/Db/BookingMapperTest.php b/tests/php/integration/Db/BookingMapperTest.php index d1e1f13984..9f5297ef6e 100644 --- a/tests/php/integration/Db/BookingMapperTest.php +++ b/tests/php/integration/Db/BookingMapperTest.php @@ -84,21 +84,13 @@ public function testFindByToken() { $token = $booking->getToken(); $booking = $this->mapper->findByToken($token); - $this->assertObjectHasAttribute('apptConfigId', $booking); $this->assertEquals('1', $booking->getApptConfigId()); - $this->assertObjectHasAttribute('createdAt', $booking); $this->assertEquals($this->time->getTime(), $booking->getCreatedAt()); - $this->assertObjectHasAttribute('token', $booking); $this->assertEquals('oken', $booking->getToken()); - $this->assertObjectHasAttribute('displayName', $booking); $this->assertEquals('Test', $booking->getDisplayName()); - $this->assertObjectHasAttribute('start', $booking); $this->assertEquals(123, $booking->getStart()); - $this->assertObjectHasAttribute('end', $booking); $this->assertEquals(123, $booking->getEnd()); - $this->assertObjectHasAttribute('email', $booking); $this->assertEquals('test@test.com', $booking->getEmail()); - $this->assertObjectHasAttribute('timezone', $booking); $this->assertEquals('Europe/Berlin', $booking->getTimezone()); }