AAE-30882 - Improved some unit tests

This commit is contained in:
VitoAlbano
2025-08-22 16:59:30 +01:00
committed by Vito Albano
parent 1aa7f27b8b
commit 3a3d202b54
4 changed files with 16 additions and 3 deletions

View File

@@ -44,6 +44,13 @@ export class BaseMock {
};
}
getBaseHeaders(): Record<string, string> {
return {
'Access-Control-Allow-Origin': '*',
'Access-Control-Allow-Credentials': 'true'
};
}
protected createNockWithCors(): nock.Scope {
this.addCorsSupport();
return nock(this.host, { encodedQueryParams: true }).defaultReplyHeaders(this.getDefaultHeaders());