mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
remove done from describe
This commit is contained in:
parent
a5d7f7acce
commit
ce7b0a3b5e
@ -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('.')
|
const versions = process.versions.node.split('.')
|
||||||
|
|
||||||
@ -2332,8 +2332,6 @@ describe('HTTP Request Node', function() {
|
|||||||
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
} else {
|
|
||||||
done()
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -61,7 +61,7 @@ describe("api/index", function() {
|
|||||||
should.not.exist(api.httpAdmin);
|
should.not.exist(api.httpAdmin);
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
describe('initalises admin api without adminAuth', function(done) {
|
describe('initalises admin api without adminAuth', function() {
|
||||||
before(function() {
|
before(function() {
|
||||||
beforeEach();
|
beforeEach();
|
||||||
api.init({},{},{},{});
|
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() {
|
before(function() {
|
||||||
beforeEach();
|
beforeEach();
|
||||||
api.init({ disableEditor: true },{},{},{});
|
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) {
|
it('ignores non-function values',function(done) {
|
||||||
api.init({ httpAdminRoot: true, httpAdminMiddleware: undefined },{},{},{});
|
api.init({ httpAdminRoot: true, httpAdminMiddleware: undefined },{},{},{});
|
||||||
const middlewareFound = api.httpAdmin._router.stack.filter((layer) => layer.name === 'testMiddleware')
|
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) {
|
it('enables an oauth/openID based authentication mechanism',function(done) {
|
||||||
const stub = sinon.stub(apiAuth, 'genericStrategy').callsFake(function(){});
|
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 = {
|
const httpAdminCors = {
|
||||||
origin: "*",
|
origin: "*",
|
||||||
methods: "GET,PUT,POST,DELETE"
|
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) {
|
it('cannot be started when editor is disabled', function (done) {
|
||||||
const stub = sinon.stub(apiEditor, 'start').callsFake(function () {
|
const stub = sinon.stub(apiEditor, 'start').callsFake(function () {
|
||||||
|
Loading…
Reference in New Issue
Block a user