From b117e190f1209725e3c6272fcea4b89f9122047a Mon Sep 17 00:00:00 2001 From: Claudia Bressi Date: Tue, 8 Aug 2023 20:53:54 +0200 Subject: [PATCH] Polish test --- ui/src/app/shared/api/task.service.spec.ts | 3 ++- ui/src/app/shared/api/task.service.ts | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ui/src/app/shared/api/task.service.spec.ts b/ui/src/app/shared/api/task.service.spec.ts index 0e9d771f3..3ec1c632a 100644 --- a/ui/src/app/shared/api/task.service.spec.ts +++ b/ui/src/app/shared/api/task.service.spec.ts @@ -147,6 +147,7 @@ describe('shared/api/task.service.ts', () => { taskService.getExecutionLogs( TaskExecution.parse({ externalExecutionId: 'foo', + schemaTarget: 'boot3', arguments: [ '--spring.cloud.data.flow.platformname=bar' ] @@ -154,7 +155,7 @@ describe('shared/api/task.service.ts', () => { ); const httpUri = mockHttp.get.calls.mostRecent().args[0]; const headerArgs = mockHttp.get.calls.mostRecent().args[1].headers; - expect(httpUri).toEqual('/tasks/logs/foo?platformName=bar&schemaTarget=boot2'); + expect(httpUri).toEqual('/tasks/logs/foo?platformName=bar&schemaTarget=boot3'); expect(headerArgs.get('Content-Type')).toEqual('application/json'); expect(headerArgs.get('Accept')).toEqual('application/json'); }); diff --git a/ui/src/app/shared/api/task.service.ts b/ui/src/app/shared/api/task.service.ts index 17a54c5a0..355f8bc45 100644 --- a/ui/src/app/shared/api/task.service.ts +++ b/ui/src/app/shared/api/task.service.ts @@ -258,7 +258,7 @@ export class TaskService { } const url = taskExecution?._links && taskExecution?._links['tasks/logs'] !== undefined ? taskExecution?._links['tasks/logs'].href : - UrlUtilities.calculateBaseApiUrl() + `tasks/logs/${taskExecution.externalExecutionId}${platformName}&schemaTarget=${taskExecution.schemaTarget}`; + UrlUtilities.calculateBaseApiUrl() + `tasks/logs/${taskExecution.externalExecutionId}?platformName=${platformName}&schemaTarget=${taskExecution.schemaTarget}`; const params = new HttpParams({encoder: new DataflowEncoder()}); return this.httpClient .get(url, {