From ce7b0a3b5eeb3a2b313790e028492aeb710d3cd8 Mon Sep 17 00:00:00 2001 From: Hiroyasu Nishiyama Date: Tue, 6 Sep 2022 18:05:50 +0900 Subject: [PATCH] remove done from describe --- test/nodes/core/network/21-httprequest_spec.js | 4 +--- test/unit/@node-red/editor-api/lib/index_spec.js | 12 ++++++------ 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/test/nodes/core/network/21-httprequest_spec.js b/test/nodes/core/network/21-httprequest_spec.js index 65f8f5814..0348dcea1 100644 --- a/test/nodes/core/network/21-httprequest_spec.js +++ b/test/nodes/core/network/21-httprequest_spec.js @@ -2268,7 +2268,7 @@ describe('HTTP Request Node', function() { }); }); - describe('should parse broken headers', function(done) { + describe('should parse broken headers', function() { const versions = process.versions.node.split('.') @@ -2332,8 +2332,6 @@ describe('HTTP Request Node', function() { }); }); - } else { - done() } }); }); diff --git a/test/unit/@node-red/editor-api/lib/index_spec.js b/test/unit/@node-red/editor-api/lib/index_spec.js index 7308fdc2d..37bb82c13 100644 --- a/test/unit/@node-red/editor-api/lib/index_spec.js +++ b/test/unit/@node-red/editor-api/lib/index_spec.js @@ -61,7 +61,7 @@ describe("api/index", function() { should.not.exist(api.httpAdmin); done(); }); - describe('initalises admin api without adminAuth', function(done) { + describe('initalises admin api without adminAuth', function() { before(function() { beforeEach(); api.init({},{},{},{}); @@ -78,7 +78,7 @@ describe("api/index", function() { }) }); - describe('initalises admin api without editor', function(done) { + describe('initalises admin api without editor', function() { before(function() { beforeEach(); api.init({ disableEditor: true },{},{},{}); @@ -95,7 +95,7 @@ describe("api/index", function() { }) }); - describe('initialises api with admin middleware', function(done) { + describe('initialises api with admin middleware', function() { it('ignores non-function values',function(done) { api.init({ httpAdminRoot: true, httpAdminMiddleware: undefined },{},{},{}); const middlewareFound = api.httpAdmin._router.stack.filter((layer) => layer.name === 'testMiddleware') @@ -112,7 +112,7 @@ describe("api/index", function() { }); }); - describe('initialises api with authentication enabled', function(done) { + describe('initialises api with authentication enabled', function() { it('enables an oauth/openID based authentication mechanism',function(done) { const stub = sinon.stub(apiAuth, 'genericStrategy').callsFake(function(){}); @@ -135,7 +135,7 @@ describe("api/index", function() { }); - describe('initialises api with custom cors config', function (done) { + describe('initialises api with custom cors config', function () { const httpAdminCors = { origin: "*", methods: "GET,PUT,POST,DELETE" @@ -156,7 +156,7 @@ describe("api/index", function() { }) }); - describe('editor start', function (done) { + describe('editor start', function () { it('cannot be started when editor is disabled', function (done) { const stub = sinon.stub(apiEditor, 'start').callsFake(function () {