From bd6d51278caaff30c2a702fff62fc3c5eac0e464 Mon Sep 17 00:00:00 2001 From: Nikita Baranov Date: Fri, 14 Feb 2025 16:22:13 +0200 Subject: [PATCH] refactor: add review comment changes --- packages/adp-tooling/src/base/project-builder.ts | 5 ++--- .../unit/writer/__snapshots__/index.test.ts.snap | 16 ++++++++-------- .../adp-tooling/test/unit/writer/index.test.ts | 2 +- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/packages/adp-tooling/src/base/project-builder.ts b/packages/adp-tooling/src/base/project-builder.ts index 9cf809351e..d61f3dc39d 100644 --- a/packages/adp-tooling/src/base/project-builder.ts +++ b/packages/adp-tooling/src/base/project-builder.ts @@ -1,13 +1,12 @@ import { CommandRunner } from '@sap-ux/nodejs-utils'; /** - * Executes a build command in the specified project directory and cleans up `.js.map` files - * in the provided target directory. + * Executes a build command in the specified project directory. * * This function uses the `CommandRunner` to run the build process via the command `npm run build`. * * @param {string} projectPath - The absolute path to the project directory where the build command will be executed. - * @returns {Promise} Resolves when the build process and cleanup are completed successfully. + * @returns {Promise} Resolves when the build process has completed successfully. * @throws {Error} If the build process fails or if an error occurs during cleanup. */ export async function runBuild(projectPath: string): Promise { diff --git a/packages/adp-tooling/test/unit/writer/__snapshots__/index.test.ts.snap b/packages/adp-tooling/test/unit/writer/__snapshots__/index.test.ts.snap index 9910a70348..e419074ea7 100644 --- a/packages/adp-tooling/test/unit/writer/__snapshots__/index.test.ts.snap +++ b/packages/adp-tooling/test/unit/writer/__snapshots__/index.test.ts.snap @@ -282,7 +282,7 @@ builder: afterTask: generateCachebusterInfo configuration: target: - destination: UYTCLNT902 + destination: DUMMY_DESTINATION app: package: $TMP ", @@ -317,14 +317,14 @@ server: configuration: adp: target: - destination: UYTCLNT902 + destination: DUMMY_DESTINATION ignoreCertErrors: false - name: fiori-tools-proxy afterMiddleware: fiori-tools-preview configuration: ignoreCertError: false # If set to true, certificate errors will be ignored. E.g. self-signed certificates will be accepted backend: - - destination: UYTCLNT902 + - destination: DUMMY_DESTINATION url: https://REQUIRED_FOR_VSCODE.example path: /sap ui5: @@ -344,7 +344,7 @@ builder: - sap: testId i18n: testKey target: - destination: UYTCLNT902 + destination: DUMMY_DESTINATION url: https://REQUIRED_FOR_VSCODE.example ", "state": "modified", @@ -1585,7 +1585,7 @@ builder: afterTask: generateCachebusterInfo configuration: target: - destination: UYTCLNT902 + destination: DUMMY_DESTINATION app: package: $TMP ", @@ -1620,14 +1620,14 @@ server: configuration: adp: target: - destination: UYTCLNT902 + destination: DUMMY_DESTINATION ignoreCertErrors: false - name: fiori-tools-proxy afterMiddleware: fiori-tools-preview configuration: ignoreCertError: false # If set to true, certificate errors will be ignored. E.g. self-signed certificates will be accepted backend: - - destination: UYTCLNT902 + - destination: DUMMY_DESTINATION url: https://REQUIRED_FOR_VSCODE.example path: /sap ui5: @@ -1647,7 +1647,7 @@ builder: - sap: testId i18n: testKey target: - destination: UYTCLNT902 + destination: DUMMY_DESTINATION url: https://REQUIRED_FOR_VSCODE.example ", "state": "modified", diff --git a/packages/adp-tooling/test/unit/writer/index.test.ts b/packages/adp-tooling/test/unit/writer/index.test.ts index f1bdb04c65..bcb891a730 100644 --- a/packages/adp-tooling/test/unit/writer/index.test.ts +++ b/packages/adp-tooling/test/unit/writer/index.test.ts @@ -198,7 +198,7 @@ describe('ADP writer', () => { reference: 'the.original.app' }, target: { - destination: 'UYTCLNT902' + destination: 'DUMMY_DESTINATION' } };