From 4556aab0605f1859e6531bd3ff18cbeec654bd7b Mon Sep 17 00:00:00 2001 From: Ed Moore Date: Fri, 20 Sep 2019 21:55:28 +1000 Subject: [PATCH 1/2] Set semaphore service to just semaphore --- lib/services/semaphore.js | 2 +- lib/services/semaphore2x.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/services/semaphore.js b/lib/services/semaphore.js index 91dcb149..530bf175 100644 --- a/lib/services/semaphore.js +++ b/lib/services/semaphore.js @@ -6,7 +6,7 @@ module.exports = { configuration: function() { console.log(' Semaphore 1.x CI Detected') return { - service: 'semaphore1x', + service: 'semaphore', build: process.env.SEMAPHORE_BUILD_NUMBER + '.' + diff --git a/lib/services/semaphore2x.js b/lib/services/semaphore2x.js index 51e3931c..985925ef 100644 --- a/lib/services/semaphore2x.js +++ b/lib/services/semaphore2x.js @@ -6,7 +6,7 @@ module.exports = { configuration: function() { console.log(' Semaphore 2.x CI Detected') return { - service: 'semaphore2x', + service: 'semaphore', branch: process.env.SEMAPHORE_GIT_BRANCH, build: process.env.SEMAPHORE_WORKFLOW_ID, commit: process.env.SEMAPHORE_GIT_SHA, From 11347a97fdd670be497caf12ba8c9190bf7eec29 Mon Sep 17 00:00:00 2001 From: Ed Moore Date: Fri, 20 Sep 2019 22:00:36 +1000 Subject: [PATCH 2/2] Fix tests --- test/services/semaphore.test.js | 2 +- test/services/semaphore2x.test.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/services/semaphore.test.js b/test/services/semaphore.test.js index 2b6f722f..405600b6 100644 --- a/test/services/semaphore.test.js +++ b/test/services/semaphore.test.js @@ -30,7 +30,7 @@ describe('Semaphore CI Provider', function() { process.env.BRANCH_NAME = 'master' process.env.SEMAPHORE_REPO_SLUG = 'owner/repo' expect(semaphore.configuration()).toEqual({ - service: 'semaphore1x', + service: 'semaphore', commit: '5678', build: '1234.1', branch: 'master', diff --git a/test/services/semaphore2x.test.js b/test/services/semaphore2x.test.js index bfb7a65e..e6f8c035 100644 --- a/test/services/semaphore2x.test.js +++ b/test/services/semaphore2x.test.js @@ -28,7 +28,7 @@ describe('Semaphore 2.x CI Provider', function() { process.env.SEMAPHORE_GIT_SHA = '5c84719708b9b649b9ef3b56af214f38cee6acde' process.env.SEMAPHORE_WORKFLOW_ID = '65c9bb1c-aeb6-41f0-b8d9-6fa177241cdf' expect(semaphore2.configuration()).toEqual({ - service: 'semaphore2x', + service: 'semaphore', branch: 'development', build: '65c9bb1c-aeb6-41f0-b8d9-6fa177241cdf', commit: '5c84719708b9b649b9ef3b56af214f38cee6acde',