mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Initial projects implementation
This commit is contained in:
@@ -23,7 +23,7 @@ var when = require('when');
|
||||
|
||||
var flow = require("../../../../red/api/admin/flow");
|
||||
|
||||
describe("flow api", function() {
|
||||
describe("api/admin/flow", function() {
|
||||
|
||||
var app;
|
||||
|
||||
|
@@ -23,7 +23,7 @@ var when = require('when');
|
||||
|
||||
var flows = require("../../../../red/api/admin/flows");
|
||||
|
||||
describe("flows api", function() {
|
||||
describe("api/admin/flows", function() {
|
||||
|
||||
var app;
|
||||
|
||||
|
@@ -24,7 +24,7 @@ var app = express();
|
||||
var info = require("../../../../red/api/admin/info");
|
||||
var theme = require("../../../../red/api/editor/theme");
|
||||
|
||||
describe("info api", function() {
|
||||
describe("api/admin/info", function() {
|
||||
describe("settings handler", function() {
|
||||
before(function() {
|
||||
sinon.stub(theme,"settings",function() { return { test: 456 };});
|
||||
|
@@ -24,7 +24,7 @@ var when = require('when');
|
||||
var nodes = require("../../../../red/api/admin/nodes");
|
||||
var apiUtil = require("../../../../red/api/util");
|
||||
|
||||
describe("nodes api", function() {
|
||||
describe("api/admin/nodes", function() {
|
||||
|
||||
var app;
|
||||
function initNodes(runtime) {
|
||||
|
@@ -17,7 +17,7 @@
|
||||
var should = require("should");
|
||||
var Clients = require("../../../../red/api/auth/clients");
|
||||
|
||||
describe("Clients", function() {
|
||||
describe("api/auth/clients", function() {
|
||||
it('finds the known editor client',function(done) {
|
||||
Clients.get("node-red-editor").then(function(client) {
|
||||
client.should.have.property("id","node-red-editor");
|
||||
@@ -41,7 +41,6 @@ describe("Clients", function() {
|
||||
}).catch(function(err) {
|
||||
done(err);
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
});
|
||||
|
@@ -24,7 +24,7 @@ var auth = require("../../../../red/api/auth");
|
||||
var Users = require("../../../../red/api/auth/users");
|
||||
var Tokens = require("../../../../red/api/auth/tokens");
|
||||
|
||||
describe("api auth middleware",function() {
|
||||
describe("api/auth/index",function() {
|
||||
|
||||
|
||||
|
||||
|
@@ -17,7 +17,7 @@
|
||||
var should = require("should");
|
||||
var permissions = require("../../../../red/api/auth/permissions");
|
||||
|
||||
describe("Auth permissions", function() {
|
||||
describe("api/auth/permissions", function() {
|
||||
describe("hasPermission", function() {
|
||||
it('a user with no permissions',function() {
|
||||
permissions.hasPermission([],"*").should.be.false();
|
||||
|
@@ -23,7 +23,7 @@ var Users = require("../../../../red/api/auth/users");
|
||||
var Tokens = require("../../../../red/api/auth/tokens");
|
||||
var Clients = require("../../../../red/api/auth/clients");
|
||||
|
||||
describe("Auth strategies", function() {
|
||||
describe("api/auth/strategies", function() {
|
||||
before(function() {
|
||||
strategies.init({log:{audit:function(){}}})
|
||||
});
|
||||
|
@@ -21,7 +21,7 @@ var sinon = require("sinon");
|
||||
var Tokens = require("../../../../red/api/auth/tokens");
|
||||
|
||||
|
||||
describe("Tokens", function() {
|
||||
describe("api/auth/tokens", function() {
|
||||
describe("#init",function() {
|
||||
it('loads sessions', function(done) {
|
||||
Tokens.init({}).then(done);
|
||||
|
@@ -20,7 +20,7 @@ var sinon = require('sinon');
|
||||
|
||||
var Users = require("../../../../red/api/auth/users");
|
||||
|
||||
describe("Users", function() {
|
||||
describe("api/auth/users", function() {
|
||||
describe('Initalised with a credentials object, no anon',function() {
|
||||
before(function() {
|
||||
Users.init({
|
||||
|
19
test/red/api/editor/projects/index_spec.js
Normal file
19
test/red/api/editor/projects/index_spec.js
Normal file
@@ -0,0 +1,19 @@
|
||||
/**
|
||||
* Copyright JS Foundation and other contributors, http://js.foundation
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
**/
|
||||
|
||||
describe("api/editor/projects", function() {
|
||||
it.skip("NEEDS TESTS WRITING",function() {});
|
||||
});
|
Reference in New Issue
Block a user