cleanup
This commit is contained in:
parent
fed9120d06
commit
2db91e7816
@ -70,8 +70,8 @@ class HsBookingItemEntityPatcherUnitTest extends PatchUnitTestBase<
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected HsBookingItemEntityPatcher createPatcher(final HsBookingItemEntity sepaMandate) {
|
protected HsBookingItemEntityPatcher createPatcher(final HsBookingItemEntity bookingItem) {
|
||||||
return new HsBookingItemEntityPatcher(sepaMandate);
|
return new HsBookingItemEntityPatcher(bookingItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -164,7 +164,7 @@ class HsBookingItemRepositoryIntegrationTest extends ContextBasedTestWithCleanup
|
|||||||
@Test
|
@Test
|
||||||
public void normalUser_canViewOnlyRelatedBookingItems() {
|
public void normalUser_canViewOnlyRelatedBookingItems() {
|
||||||
// given:
|
// given:
|
||||||
context("bankaccount-admin@FirstGmbH.example.com");
|
context("person-FirbySusan@example.com");
|
||||||
final var debitorUuid = debitorRepo.findDebitorByDebitorNumber(1000111).stream().findAny().orElseThrow().getUuid();
|
final var debitorUuid = debitorRepo.findDebitorByDebitorNumber(1000111).stream().findAny().orElseThrow().getUuid();
|
||||||
|
|
||||||
// when:
|
// when:
|
||||||
@ -212,15 +212,6 @@ class HsBookingItemRepositoryIntegrationTest extends ContextBasedTestWithCleanup
|
|||||||
assertThat(found).isNotEmpty().get().isNotSameAs(saved)
|
assertThat(found).isNotEmpty().get().isNotSameAs(saved)
|
||||||
.extracting(Object::toString).isEqualTo(saved.toString());
|
.extracting(Object::toString).isEqualTo(saved.toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
private void assertThatBookingItemIsVisibleForUserWithRole(
|
|
||||||
final HsBookingItemEntity entity,
|
|
||||||
final String assumedRoles) {
|
|
||||||
jpaAttempt.transacted(() -> {
|
|
||||||
context("superuser-alex@hostsharing.net", assumedRoles);
|
|
||||||
assertThatBookingItemActuallyInDatabase(entity);
|
|
||||||
}).assertSuccessful();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Nested
|
@Nested
|
||||||
|
Loading…
Reference in New Issue
Block a user