From e5d80a069694b282d38b8dedd685b0cf3342c702 Mon Sep 17 00:00:00 2001 From: John McLear Date: Wed, 27 Jan 2021 20:45:23 +0000 Subject: [PATCH] lint and timeouts for instance.js --- tests/backend/specs/api/instance.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/backend/specs/api/instance.js b/tests/backend/specs/api/instance.js index 7da967ed2..78e5b19c2 100644 --- a/tests/backend/specs/api/instance.js +++ b/tests/backend/specs/api/instance.js @@ -1,3 +1,5 @@ +'use strict'; + /* * Tests for the instance-level APIs * @@ -14,6 +16,7 @@ const apiVersion = '1.2.14'; describe(__filename, function () { describe('Connectivity for instance-level API tests', function () { it('can connect', function (done) { + this.timeout(150); api.get('/api/') .expect('Content-Type', /json/) .expect(200, done); @@ -22,6 +25,7 @@ describe(__filename, function () { describe('getStats', function () { it('Gets the stats of a running instance', function (done) { + this.timeout(100); api.get(endPoint('getStats')) .expect((res) => { if (res.body.code !== 0) throw new Error('getStats() failed'); @@ -44,7 +48,7 @@ describe(__filename, function () { }); }); -var endPoint = function (point, version) { +const endPoint = function (point, version) { version = version || apiVersion; return `/api/${version}/${point}?apikey=${apiKey}`; };