From 926bcc56d6d5296b0430126951676ae82ade4f4d Mon Sep 17 00:00:00 2001 From: Quentin Date: Wed, 18 Dec 2024 22:46:12 +0100 Subject: [PATCH] Sonar/Angular: Assertions should be complete --- .../app/admin/health/health.component.spec.ts.mustache | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/main/resources/generator/client/angular/admin/src/main/webapp/app/admin/health/health.component.spec.ts.mustache b/src/main/resources/generator/client/angular/admin/src/main/webapp/app/admin/health/health.component.spec.ts.mustache index effe87303dd..1be0af988b3 100644 --- a/src/main/resources/generator/client/angular/admin/src/main/webapp/app/admin/health/health.component.spec.ts.mustache +++ b/src/main/resources/generator/client/angular/admin/src/main/webapp/app/admin/health/health.component.spec.ts.mustache @@ -39,11 +39,10 @@ describe('HealthComponent', () => { comp.ngOnInit(); expect(service.checkHealth).toHaveBeenCalled(); - expect( - service.checkHealth().subscribe({ - next: () => expect(comp.datasource).toEqual([{ details: { mailDetail: 'mail' }, key: 'mail', status: 'UP' }]), - }), - ); + + service.checkHealth().subscribe(() => { + expect(comp.datasource).toEqual([{ details: { mailDetail: 'mail' }, key: 'mail', status: 'UP' }]); + }); }); it('should call checkHealth on refresh', () => {