diff --git a/.travis.yml b/.travis.yml index e6a8d73916..38b57c2251 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,6 +14,7 @@ env: - PLATFORM_SERVICE=core/jazz_email - PLATFORM_SERVICE=core/jazz_environment-event-handler - PLATFORM_SERVICE=core/jazz_environments + - PLATFORM_SERVICE=core/jazz_es-kinesis-log-streamer - PLATFORM_SERVICE=core/jazz_events - PLATFORM_SERVICE=core/jazz_events-handler - PLATFORM_SERVICE=core/jazz_is-service-available diff --git a/core/jazz_assets/package.json b/core/jazz_assets/package.json index 44f8b5c20a..13b0cbf881 100644 --- a/core/jazz_assets/package.json +++ b/core/jazz_assets/package.json @@ -16,7 +16,7 @@ "lodash": "*", "moment": "*", "request": "*", - "uuid": "*" + "uuid": "^3.3.2" }, "devDependencies": { "aws-lambda-mock-context": "^3.1.1", @@ -28,4 +28,4 @@ "mocha": "^v3.0.0", "sinon": "^5.0.10" } -} \ No newline at end of file +} diff --git a/core/jazz_codeq/test/test.js b/core/jazz_codeq/test/test.js index 3151dc1220..7d136550f8 100755 --- a/core/jazz_codeq/test/test.js +++ b/core/jazz_codeq/test/test.js @@ -329,7 +329,7 @@ describe('validation tests', () => { }); it('should return null when from date is invalid', () => { - const validFrom = validation.validateFromDate(1234); + const validFrom = validation.validateFromDate('BAD 123 - 1date'); expect(validFrom).to.eql(null); }); @@ -351,7 +351,7 @@ describe('validation tests', () => { }); it('should return null when to date is invalid', () => { - const validFrom = validation.validateToDate(1234); + const validFrom = validation.validateToDate('BAD 123 - 1date'); expect(validFrom).to.eql(null); }); diff --git a/core/jazz_deployments/package.json b/core/jazz_deployments/package.json index 43fe40328c..ebe49eaf30 100644 --- a/core/jazz_deployments/package.json +++ b/core/jazz_deployments/package.json @@ -15,7 +15,7 @@ "lodash": "*", "moment": "*", "request": "*", - "uuid": "*" + "uuid": "^3.3.2" }, "devDependencies": { "aws-lambda-mock-context": "^3.1.1", @@ -26,4 +26,4 @@ "mocha": "^v3.0.0", "sinon": "^5.0.7" } -} \ No newline at end of file +} diff --git a/core/jazz_es-kinesis-log-streamer/package.json b/core/jazz_es-kinesis-log-streamer/package.json index 2f9a5b1392..a5858da307 100644 --- a/core/jazz_es-kinesis-log-streamer/package.json +++ b/core/jazz_es-kinesis-log-streamer/package.json @@ -14,7 +14,7 @@ "dependencies": { "unicode-byte-truncate": "*", "request": "*", - "uuid": "*" + "uuid": "^3.3.2" }, "devDependencies": { "aws-lambda-mock-context": "^3.2.1", @@ -24,4 +24,4 @@ "nyc": "^13.3.0", "mocha": "^v3.0.0" } -} \ No newline at end of file +} diff --git a/core/jazz_es-kinesis-log-streamer/test/test.js b/core/jazz_es-kinesis-log-streamer/test/test.js index 517cc3cde7..a1a793823a 100644 --- a/core/jazz_es-kinesis-log-streamer/test/test.js +++ b/core/jazz_es-kinesis-log-streamer/test/test.js @@ -150,9 +150,8 @@ describe('jazz_es-kinesis-log-stream', function () { let payload, expected, response, request, data; beforeEach(function () { payload = { - "host": config.ES_ENDPOINT, + "url": 'https://' + config.ES_ENDPOINT + '/_bulk', "method": "POST", - "path": "/_bulk", "body": "Sample data", "headers": { "Content-Type": "application/json", @@ -221,11 +220,12 @@ describe('jazz_es-kinesis-log-stream', function () { response.write(JSON.stringify(expected)); response.end(); + let buildRequest = sinon.stub(utils, "buildRequest").returns(payload); this.request = sinon.stub(https, 'request'); this.request.callsArgWith(1, response) .returns(request); - let buildRequest = sinon.stub(utils, "buildRequest").returns(payload); + index.post(config, "hello world", (error, success, response, failedItems) => { expect(error).to.have.all.keys('statusCode', 'responseBody'); @@ -418,7 +418,7 @@ describe('jazz_es-kinesis-log-stream', function () { describe('buildRequest', () => { it('should successfully return build request payload', () => { let res = utils.buildRequest(config.ES_ENDPOINT, "sample text"); - expect(res).to.have.all.keys('host', 'method', 'path', 'body', 'headers'); + expect(res).to.have.all.keys('url', 'method', 'body', 'headers'); }) }) diff --git a/core/jazz_events/package.json b/core/jazz_events/package.json index fb9323b2d9..03a25af587 100644 --- a/core/jazz_events/package.json +++ b/core/jazz_events/package.json @@ -12,7 +12,7 @@ "dependencies": { "moment": "*", "request": "*", - "uuid": "*" + "uuid": "^3.3.2" }, "devDependencies": { "chai": "^3.5.0", @@ -27,4 +27,4 @@ "lambda-local": "^1.4.2", "sinon": "^1.17.7" } -} \ No newline at end of file +}