Skip to content

Commit

Permalink
commit for version 2.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
vamsee committed Apr 30, 2020
2 parents 695b71b + 6513e83 commit a540b00
Show file tree
Hide file tree
Showing 13 changed files with 142 additions and 175 deletions.
13 changes: 6 additions & 7 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
/client/
/coverage/
/node_modules/
server/dropdb.js
/lib/expression-language/expression-syntax-parser.js
build/
client/
coverage/
node_modules/
test/
drop.js
/test/

Gruntfile.js
2 changes: 1 addition & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@
"no-undefined": 1, // http://eslint.org/docs/rules/no-undefined
"no-with": 2, // http://eslint.org/docs/rules/no-with
"handle-callback-err": 1, // http://eslint.org/docs/rules/handle-callback-err
"radix": 2, // http://eslint.org/docs/rules/radix
"radix": 0, // http://eslint.org/docs/rules/radix
"wrap-iife": [2, "any"], // http://eslint.org/docs/rules/wrap-iife
"yoda": 2, // http://eslint.org/docs/rules/yoda

Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,4 @@ out/
*.zip
/common/models/test
package-lock.json
oracle-user.sh
38 changes: 1 addition & 37 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,38 +10,6 @@ module.exports = function GruntConfig(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),

mkdir: {
all: {
options: {
create: ['dist']
}
}
},

copy: {
main: {
files: [
// includes files within path and its sub-directories
{
expand: true,
src: ['**', '!node_modules/**', '!coverage/**'],
dest: 'dist/'
}
]
}
},

mochaTest: {
test: {
options: {
quiet: false,
clearRequireCache: true,
timeout: 100000
},
src: ['test/test.js']
}
},

clean: {
coverage: {
src: ['coverage/']
Expand Down Expand Up @@ -72,12 +40,8 @@ module.exports = function GruntConfig(grunt) {
});

// Add the grunt-mocha-test tasks.
grunt.loadNpmTasks('grunt-mocha-test');
grunt.loadNpmTasks('grunt-mocha-istanbul');
grunt.loadNpmTasks('grunt-contrib-clean');

grunt.loadNpmTasks('grunt-mkdir');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-mocha-istanbul');

grunt.registerTask('test-with-coverage', ['clean:coverage', 'mocha_istanbul']);
};
17 changes: 6 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "oe-node-red-nodes",
"version": "2.1.0",
"version": "2.2.0",
"description": "Node-RED nodes for oeCloud based applications",
"main": "node-red.js",
"scripts": {
Expand Down Expand Up @@ -47,26 +47,21 @@
"devDependencies": {
"babel-eslint": "7.2.3",
"chai": "3.4.1",
"chai-datetime": "1.4.0",
"chai-things": "0.2.0",
"chalk": "1.1.1",
"eslint": "4.10.0",
"grunt": "1.0.4",
"grunt-banner": "0.6.0",
"grunt-cli": "1.3.2",
"grunt-contrib-clean": "2.0.0",
"grunt-contrib-copy": "1.0.0",
"grunt-jsbeautifier": "0.2.13",
"grunt-mkdir": "1.0.0",
"grunt-mocha-istanbul": "5.0.2",
"grunt-mocha-test": "0.13.3",
"istanbul": "0.4.5",
"oe-node-red": "^2.0.0",
"mocha": "5.2.0",
"oe-cloud": "^2.0.0",
"oe-multi-tenancy": "^2.0.0",
"loopback-connector-mongodb": "3.9.2",
"oe-connector-mongodb": "^2.0.0",
"oe-connector-oracle": "^2.0.0",
"oe-connector-postgresql": "^2.0.0",
"mocha": "5.2.0",
"oe-multi-tenancy": "^2.0.0",
"oe-node-red": "^2.0.0",
"superagent-defaults": "0.1.14",
"supertest": "3.4.2"
}
Expand Down
23 changes: 13 additions & 10 deletions postinstall.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,22 @@
var fs = require('fs');
var deleteFolderRecursive = function(path) {
if( fs.existsSync(path) ) {
fs.readdirSync(path).forEach(function(file,index){
var curPath = path + "/" + file;
if(fs.lstatSync(curPath).isDirectory()) { // recurse
var deleteFolderRecursive = function (path) {
if (fs.existsSync(path)) {
fs.readdirSync(path).forEach(function (file, index) {
var curPath = path + '/' + file;
// recurse
if (fs.lstatSync(curPath).isDirectory()) {
deleteFolderRecursive(curPath);
} else { // delete file
} else {
// delete file
fs.unlinkSync(curPath);
}
});
fs.rmdirSync(path);
}
};
var initDir = process.env.INIT_CWD;
deleteFolderRecursive(initDir + "/node_modules/node-red-node-email");
deleteFolderRecursive(initDir + "/node_modules/mailparser");
deleteFolderRecursive(initDir + "/node_modules/mimelib");
console.log("Removed node-red-node-email module");
deleteFolderRecursive(initDir + '/node_modules/node-red-node-email');
deleteFolderRecursive(initDir + '/node_modules/mailparser');
deleteFolderRecursive(initDir + '/node_modules/mimelib');
// eslint-disable-next-line no-console
console.log('Removed node-red-node-email module');
1 change: 1 addition & 0 deletions test/app-list.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
},
{
"path": "oe-multi-tenancy",
"autoEnableMixins" : true,
"enabled": true
},
{
Expand Down
3 changes: 1 addition & 2 deletions test/datasources.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,14 @@
"name": "transient",
"connector": "transient"
},

"db": {
"host": "localhost",
"port": 27017,
"url": "mongodb://localhost:27017/oe-node-red-nodes-test",
"database": "oe-node-red-nodes-test",
"password": "admin",
"name": "db",
"connector": "mongodb",
"connector": "oe-connector-mongodb",
"user": "admin",
"connectionTimeout": 500000,
"connectTimeoutMS": 500000,
Expand Down
12 changes: 5 additions & 7 deletions test/datasources.mongo.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
*
*/
var mongoHost = process.env.MONGO_HOST || 'localhost';
var mongoPort = process.env.MONGO_PORT ? parseInt(process.env.MONGO_PORT) : 27017;
var dbName = process.env.DB_NAME || 'oe-node-red-nodes-test';
module.exports =
{
module.exports = {
'memdb': {
'name': 'memdb',
'connector': 'memory'
Expand All @@ -18,13 +18,11 @@ module.exports =
},
'db': {
'host': mongoHost,
'port': 27017,
'url': 'mongodb://' + mongoHost + ':27017/' + dbName,
'port': mongoPort,
'url': 'mongodb://' + mongoHost + ':' + mongoPort + '/' + dbName,
'database': dbName,
'password': 'admin',
'name': 'db',
'connector': 'mongodb',
'user': 'admin',
'connector': 'oe-connector-mongodb',
'connectionTimeout': 500000
}
};
Expand Down
10 changes: 2 additions & 8 deletions test/datasources.oracle.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,10 @@
* Bangalore, India. All Rights Reserved.
*
*/
/**
**
** ©2016-2017 EdgeVerve Systems Limited (a fully owned Infosys subsidiary),
** Bangalore, India. All Rights Reserved.
**
**/

var oracleSID = process.env.ORACLE_SID || 'orclpdb.ad.infosys.com';
var oracleSID = process.env.ORACLE_SID || 'ORCLCDB';
var oracleHost = process.env.ORACLE_HOST || 'localhost';
var oraclePort = process.env.ORACLE_PORT || 1521;
var oraclePort = process.env.ORACLE_PORT ? parseInt(process.env.ORACLE_PORT) : 1521;
var oracleUserName = process.env.ORACLE_USERNAME || 'oeadmin';
var oracleUserPassword = process.env.ORACLE_PASSWORD || 'oeadmin';

Expand Down
9 changes: 4 additions & 5 deletions test/datasources.postgres.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
*
*/
var postgresHost = process.env.POSTGRES_HOST || 'localhost';
var postgresPort = process.env.POSTGRES_PORT ? parseInt(process.env.POSTGRES_PORT) : 5432;
var dbName = process.env.DB_NAME || 'oe-node-red-nodes-test';
module.exports =
{
module.exports = {
'memdb': {
'name': 'memdb',
'connector': 'memory'
Expand All @@ -16,11 +16,10 @@ module.exports =
'name': 'transient',
'connector': 'transient'
},

'db': {
'host': postgresHost,
'port': 5432,
'url': 'postgres://postgres:postgres@' + postgresHost + ':5432/' + dbName,
'port': postgresPort,
'url': 'postgres://postgres:postgres@' + postgresHost + ':' + postgresPort + '/' + dbName,
'database': dbName,
'password': 'postgres',
'name': 'db',
Expand Down
12 changes: 6 additions & 6 deletions test/node-red-settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ module.exports = {

// Node-RED scans the `nodes` directory in the install directory to find nodes.
// The following property can be used to specify an additional directory to scan.
nodesDir: './',
nodesDir: './'

// By default, the Node-RED UI is available at http://localhost:1880/
// The following property can be used to specify a different root path.
Expand Down Expand Up @@ -204,11 +204,11 @@ module.exports = {
// context.global.os

// functionGlobalContext: {
// os:require('os'),
// octalbonescript:require('octalbonescript'),
// jfive:require("johnny-five"),
// j5board:require("johnny-five").Board({repl:false})
//}
// os:require('os'),
// octalbonescript:require('octalbonescript'),
// jfive:require("johnny-five"),
// j5board:require("johnny-five").Board({repl:false})
// }

// The following property can be used to order the categories in the editor
// palette. If a node's category is not in the list, the category will get
Expand Down
Loading

0 comments on commit a540b00

Please sign in to comment.