From 99af79fcf3c01cfcd8e9a13de57f0827febdf363 Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Thu, 26 Apr 2018 12:49:00 +0100 Subject: [PATCH] Add missing test resources --- .../node_modules/EmptyModule/file.txt | 1 + .../TestNodeModule/TestNodeModule.html | 5 +++++ .../node_modules/TestNodeModule/TestNodeModule.js | 5 +++++ .../TestNodeModule/TestNodeModule2.html | 5 +++++ .../TestNodeModule/TestNodeModule2.js | 4 ++++ .../TestNodeModule/icons/arrow-in.png | Bin 0 -> 393 bytes .../node_modules/TestNodeModule/icons/file.txt | 3 +++ .../node_modules/TestNodeModule/package.json | 11 +++++++++++ .../VersionMismatchModule/TestNodeModule.html | 5 +++++ .../VersionMismatchModule/TestNodeModule.js | 5 +++++ .../VersionMismatchModule/TestNodeModule2.html | 5 +++++ .../VersionMismatchModule/TestNodeModule2.js | 4 ++++ .../VersionMismatchModule/icons/file.txt | 3 +++ .../VersionMismatchModule/package.json | 12 ++++++++++++ 14 files changed, 68 insertions(+) create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/EmptyModule/file.txt create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.html create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.js create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.html create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.js create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/icons/arrow-in.png create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/icons/file.txt create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/package.json create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.html create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.js create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.html create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.js create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/icons/file.txt create mode 100644 test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/package.json diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/EmptyModule/file.txt b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/EmptyModule/file.txt new file mode 100644 index 000000000..0ce8dcaed --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/EmptyModule/file.txt @@ -0,0 +1 @@ +This file exists just to ensure the parent directory is in the repository. diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.html b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.html new file mode 100644 index 000000000..17483f7ca --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.html @@ -0,0 +1,5 @@ + + + + +

this should be filtered out

diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.js b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.js new file mode 100644 index 000000000..c79c2ceb6 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule.js @@ -0,0 +1,5 @@ +// A test node that exports a function +module.exports = function(RED) { + function TestNode(n) {} + RED.nodes.registerType("test-node-mod-1",TestNode); +} diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.html b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.html new file mode 100644 index 000000000..a1f1b6c79 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.html @@ -0,0 +1,5 @@ + + + + +

this should be filtered out

diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.js b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.js new file mode 100644 index 000000000..d359fb3f2 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/TestNodeModule2.js @@ -0,0 +1,4 @@ +// A test node that exports a function +module.exports = function(RED) { + throw new Error("fail to load"); +} diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/icons/arrow-in.png b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/icons/arrow-in.png new file mode 100644 index 0000000000000000000000000000000000000000..e38f3914600901b736f5fa18786ee11be6d41c28 GIT binary patch literal 393 zcmeAS@N?(olHy`uVBq!ia0vp^B0wz1!3HFCgzU0`6icy_X9x!n)NrJ90QsB+9+AZi z3~X;em{G3O!W1YdS>hT|5}cn_Ql40p%1~Zju9umYU7Va)kgAtols@~NjT8d|Bb%p- zV~9uR+N-+$hZ97Oeyp#Y$RU!&XX#m>@|$agvYL9Jz$O6}72y^gZVi>ZMeaH^t*Q|! zLhVk<0xdko8zYVo#8M-LBBd8b>1kw|i?FO)bWqsy_rwQg27N4y zeX6pqO$_Cex^^A7_NsS@+=bOASA^wN0&GKN(hlAguRU&q- jTBY?`*L>xN+|S&+7B*edvmQhOgN?z{)z4*}Q$iB}+9!`i literal 0 HcmV?d00001 diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/icons/file.txt b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/icons/file.txt new file mode 100644 index 000000000..59a29af14 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/icons/file.txt @@ -0,0 +1,3 @@ +This file exists just to ensure the 'icons' directory is in the repository. +TODO: a future test needs to ensure the right icon files are loaded - this + directory can be used for that diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/package.json b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/package.json new file mode 100644 index 000000000..8eba5b04b --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/TestNodeModule/package.json @@ -0,0 +1,11 @@ +{ + "name" : "TestNodeModule", + "version" : "0.0.1", + "description" : "A test node module", + "node-red" : { + "nodes": { + "TestNodeMod1": "TestNodeModule.js", + "TestNodeMod2": "TestNodeModule2.js" + } + } +} diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.html b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.html new file mode 100644 index 000000000..17483f7ca --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.html @@ -0,0 +1,5 @@ + + + + +

this should be filtered out

diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.js b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.js new file mode 100644 index 000000000..c79c2ceb6 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule.js @@ -0,0 +1,5 @@ +// A test node that exports a function +module.exports = function(RED) { + function TestNode(n) {} + RED.nodes.registerType("test-node-mod-1",TestNode); +} diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.html b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.html new file mode 100644 index 000000000..a1f1b6c79 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.html @@ -0,0 +1,5 @@ + + + + +

this should be filtered out

diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.js b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.js new file mode 100644 index 000000000..d359fb3f2 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/TestNodeModule2.js @@ -0,0 +1,4 @@ +// A test node that exports a function +module.exports = function(RED) { + throw new Error("fail to load"); +} diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/icons/file.txt b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/icons/file.txt new file mode 100644 index 000000000..59a29af14 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/icons/file.txt @@ -0,0 +1,3 @@ +This file exists just to ensure the 'icons' directory is in the repository. +TODO: a future test needs to ensure the right icon files are loaded - this + directory can be used for that diff --git a/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/package.json b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/package.json new file mode 100644 index 000000000..4f9e46518 --- /dev/null +++ b/test/red/runtime-registry/resources/local/TestNodeModule/node_modules/VersionMismatchModule/package.json @@ -0,0 +1,12 @@ +{ + "name" : "VersionMismatchModule", + "version" : "0.0.1", + "description" : "A test node module", + "node-red" : { + "version": "100.0.0", + "nodes": { + "VersionMismatchMod1": "TestNodeModule.js", + "VersionMismatchMod2": "TestNodeModule2.js" + } + } +}