diff --git a/package.json b/package.json index a8afeed..c754b56 100755 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "uilicious-cli", - "version": "5.1.8", + "version": "5.1.9", "description": "Uilicious CLI toolchain", "main": "uilicious-cli.js", "keywords": [ diff --git a/src/cli-command/project/run.js b/src/cli-command/project/run.js index 6fe638c..53c5720 100644 --- a/src/cli-command/project/run.js +++ b/src/cli-command/project/run.js @@ -152,6 +152,14 @@ class TestRunnerSession { webstudioURL = argv.apiHost.split("/api/")[0]+"/webstudio" } + // Normalize ending slash + if( webstudioURL.endsWith("/") ) { + webstudioURL.slice(0, webstudioURL.length - 1) + } + if( privateSnippetURL != null && privateSnippetURL.endsWith("/") ) { + privateSnippetURL.slice(0, privateSnippetURL.length - 1) + } + // Get the full project listing (after login) let projectObj = await SpaceAndProjectApi.findProject(argv.project); let projectID = projectObj._oid; @@ -681,12 +689,12 @@ class TestRunnerSession { if( this.testCodeDir == null ) { resultMsg.push(`> See full results at : ${this.webstudioURL}/project/${this.projectID}/editor/${this.uriEncodedScriptPath}?testRunId=${this.testID}`) } - resultMsg.push(`> See result snippet at : ${this.privateSnippetURL}${this.testID}`) + resultMsg.push(`> See result snippet at : ${this.privateSnippetURL}/${this.testID}`) resultMsg.push(">") // Or json this.jsonOutputObj.webstudioURL = `${this.webstudioURL}/project/${this.projectID}/editor/${this.uriEncodedScriptPath}?testRunId=${this.testID}`; - this.jsonOutputObj.snippetURL = `${this.privateSnippetURL}${this.testID}`; + this.jsonOutputObj.snippetURL = `${this.privateSnippetURL}/${this.testID}`; } else { // This is the on-premise version !!! diff --git a/src/version.js b/src/version.js index 68ebe14..39b9db2 100755 --- a/src/version.js +++ b/src/version.js @@ -1 +1 @@ -module.exports = "5.1.8" \ No newline at end of file +module.exports = "5.1.9" \ No newline at end of file