### Question:
ConsentEntity extends InstanceDependableEntity implements Authorisable { @Override public String getInternalRequestId(AuthorisationType authorisationType) { if (authorisationType == AuthorisationType.CONSENT) { return internalRequestId; } throw new IllegalArgumentException("Invalid authorisation type: " + authorisationType); }  @PostLoad void consentPostLoad(); @PreUpdate void consentPreUpdate(); @PrePersist void consentPrePersist(); boolean isConfirmationExpired(long expirationPeriodMs); void addUsage(AisConsentUsage aisConsentUsage); boolean isWrongConsentData(); boolean isExpiredByDate(); boolean shouldConsentBeExpired(); boolean isNonReccuringAlreadyUsed(); boolean isOneAccessType(); @Override String getInternalRequestId(AuthorisationType authorisationType);  }### Answer:
@Test void getInternalRequestId_AisAuthorisation() { ConsentEntity aisConsent = new ConsentEntity(); String expectedInternalRequestId = "internal-request-id"; aisConsent.setInternalRequestId(expectedInternalRequestId); String actualInternalRequestId = aisConsent.getInternalRequestId(AuthorisationType.CONSENT); assertEquals(expectedInternalRequestId, actualInternalRequestId); }
@Test void getInternalRequestId_PisAuthorisation_shouldThrowException() { ConsentEntity aisConsent = new ConsentEntity(); assertThrows(IllegalArgumentException.class, () -> aisConsent.getInternalRequestId(AuthorisationType.PIS_CREATION)); }