1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00
Commit Graph

1344 Commits

Author SHA1 Message Date
Nick O'Leary
d802ce1484
Merge pull request #3460 from ArFe/feature-add-store-external-token-when-authenticate
Feature add: Store external token when authenticate if provided
2022-04-22 09:51:20 +01:00
Steve-Mcl
4b10b9ffc3 update tests 2022-04-21 21:32:24 +01:00
Nick O'Leary
4884938036
Merge branch 'master' into dev 2022-04-21 16:05:54 +01:00
Nick O'Leary
3a26c5cd65
Merge pull request #3498 from sammachin/sammachin_credentials
Error on invalid encrypted credentials
2022-04-21 10:59:43 +01:00
Nick O'Leary
958f57085f
Merge branch 'dev' into tcp-node-better-split 2022-04-20 09:34:16 +01:00
Steve-Mcl
013af7619e add tests
- fix 2 issues found when developing tests :)
2022-04-16 17:13:54 +01:00
Steve-Mcl
8ba6a7436e Add tests for MQTT v5 auto parsing hints 2022-04-15 18:21:36 +01:00
Steve-Mcl
39f303fcd6 add unit tests 2022-04-06 15:11:37 +01:00
Stephen McLaughlin
a7932da207
Merge pull request #3488 from Steve-Mcl/httpreq-headers-ui
Add UI for Http Request node headers
2022-04-06 08:35:32 +01:00
Sam Machin
50718495da
fix test mock 2022-03-24 08:39:31 +00:00
Dave Conway-Jones
8a40622815
tcp node - undo trim if we re-add split chars
and fix tests
2022-03-23 22:07:43 +00:00
Steve-Mcl
b918b75414 Merge remote-tracking branch 'upstream/master' into dev 2022-03-23 11:16:18 +00:00
Stephen McLaughlin
f660973168
Dont run MQTT tests by default on local
- update skip message to inform use of how to enable test
2022-03-23 10:00:36 +00:00
Stephen McLaughlin
cf2e7744f3
remove copyright header
Co-authored-by: Nick O'Leary <nick.oleary@gmail.com>
2022-03-23 09:15:57 +00:00
Steve-Mcl
ecf1847dd2 use CI flag to skip MQTT tests 2022-03-21 14:59:10 +00:00
Steve-Mcl
40a9dce869 try broker.emqx.io 2022-03-21 13:51:20 +00:00
Steve-Mcl
a6696733fa tidy up code 2022-03-21 13:50:24 +00:00
Sam Machin
d9bd736159
change error to warn for moving from unencrypted to encrypted 2022-03-21 09:29:41 +00:00
Sam Machin
c7f48a83c0
add test 2022-03-19 17:57:30 +00:00
Steve-Mcl
497d63e67e Add unit tests for MQTT nodes 2022-03-19 17:29:31 +00:00
Steve-Mcl
31b3a4c342 Add UI for common headers/values
- Wrap HTML node script in IFFE (isolate module level vars & functions)
- Add UI elements for setting headers in http req node edit form
- Update built in help
- Add tests
2022-03-12 13:47:29 +00:00
Steve-Mcl
249f7e45fb Link Call should not call into subflow...
- includes missing jsdoc
- improves speed (no searching, only lookups)
- code formatting consistency
- improve tests
2022-02-28 13:57:22 +00:00
Ariel Ferreira
79a789c557 add test to check if in the case user contains token, Node-RED uses it instead of generating a new Token 2022-02-26 17:24:59 -05:00
Dave Conway-Jones
bda5dffa34
Add tests 2022-02-25 16:19:20 +00:00
Steve-Mcl
29df7e84a1 add tests 2022-02-25 16:13:48 +00:00
Dave Conway-Jones
0398ef3b90
undo regression in tcp-in node (missed one)
and add test
2022-02-25 16:06:44 +00:00
Nick O'Leary
0533c08438
Merge branch 'master' into dev 2022-02-18 22:02:30 +00:00
Hiroyasu Nishiyama
0f1aea3e0d add test case 2022-02-15 14:41:03 +09:00
Nick O'Leary
95d3a8cc22
Merge pull request #3409 from node-red/let-switch-number-test-report-NaN-as-false
switch node - add check for NaN in is of type number to be false
2022-02-14 23:17:38 +00:00
Dave Conway-Jones
63ebadc526
add check for NaN in is of type number to be false
and add test
to fix issue #3408
2022-02-09 12:03:38 +00:00
Alexandre Alapetite
280d63fde7
Fix util.encodeObject 2022-02-03 15:59:25 +01:00
Nick O'Leary
5b428bb8e6
Merge pull request #3379 from node-red-hitachi/nr_node_path-support
add NR_NODE_PATH path support
2022-01-26 14:29:03 +00:00
Hiroyasu Nishiyama
c948ff88a5 add support of NR_NODE_PATH 2022-01-26 21:24:48 +09:00
Nick O'Leary
4173625fca
Merge pull request #3243 from node-red/delete-global-context
Clear context contents when switching projects
2022-01-26 11:28:34 +00:00
Hiroyasu Nishiyama
aa3f5001d5 additional update of test for NR_ prefix addition 2022-01-26 10:52:41 +09:00
Hiroyasu Nishiyama
56580c4005 add test for NR_ prefix addition 2022-01-26 09:26:05 +09:00
Hiroyasu Nishiyama
983dad5b53 add test for env var access of GROUP_ID & GROUP_NAME 2022-01-25 21:07:38 +09:00
Hiroyasu Nishiyama
0ad60013aa add test for env var access of FLOW_ID & FLOW_NAME 2022-01-25 20:52:45 +09:00
Hiroyasu Nishiyama
75bcd9e8d5 add support for accessing node id & name as env var 2022-01-14 23:40:12 +09:00
Nick O'Leary
3abef972a7
Clear context contents when switching projects
Fixes #3240
2022-01-12 18:59:29 +00:00
Nick O'Leary
30b00741b5
Merge pull request #3296 from node-red/Json-try-parse-buffer
Let JSON node attempt to parse buffer if it contains a valid string
2022-01-12 18:58:02 +00:00
Nick O'Leary
f86e743cce
Merge branch 'master' into dev 2022-01-12 17:59:26 +00:00
Nick O'Leary
ee84eb666b
Merge pull request #3307 from node-red/add-tls-option-to-tcp-node
Add TLS option to tcp client nodes
2022-01-12 17:37:43 +00:00
Tobias Oort
555f155cad Added support for commaseparated subprotocols
Removed placeholder from html
2022-01-12 09:10:35 +01:00
Dave Conway-Jones
52e4e0e569
Fix for narrrowbandEq mode start condition failure
And add test
As discussed https://discourse.nodered.org/t/the-filter-node-or-the-old-rbe-node/56371
2022-01-11 13:56:44 +00:00
Tobias Oort
83203d5f5d
Fixed property name in unit-test 2022-01-10 22:23:45 +01:00
Tobias Oort
bd77d7eec3 Implemented support for Websocket Subprotocols in WS Client Node. 2022-01-08 22:18:05 +01:00
Dave Conway-Jones
c9f03f1ac5
better tests
(and a small fix as a result)
2021-12-27 09:51:50 +00:00
Dave Conway-Jones
02bd292b8c
fix and test 2021-12-26 16:12:47 +00:00
Dave Conway-Jones
6ae42eb787
Let JSON parser attempt to parse buffers if they contain strings
and add/fix test
2021-12-10 15:21:43 +00:00
Hiroyasu Nishiyama
c331da7323 fix env var access using $env for groups 2021-11-27 19:29:57 +09:00
Nick O'Leary
21304a695c
Fix tcprequest deprecation warnings 2021-10-21 09:40:25 +01:00
Nick O'Leary
4adad6e424
Merge pull request #3166 from node-red/output-discarded-rate-limit
Delay node: add option to send intermediate messages on separate output
2021-10-06 17:34:44 +01:00
Nick O'Leary
012e1cbcc5
Improve unit test coverage 2021-10-04 17:53:14 +01:00
Nick O'Leary
1c18641699
Delay node: add option to send intermediate messages on separate output 2021-10-04 13:00:24 +01:00
Nick O'Leary
81a278dd8c
Merge pull request #3156 from node-red/change-clone
Add option to deep-clone properties in Change node
2021-10-04 10:54:52 +01:00
Nick O'Leary
da114fa3a5
Merge pull request #3152 from node-red/link-call
Add Link Call node
2021-10-01 15:59:43 +01:00
Nick O'Leary
ec27e19e3f
Add unit tests for Join restartTimeout and update help 2021-09-30 10:59:45 +01:00
Nick O'Leary
7fffc1a36d
Merge pull request #3069 from node-red/delay-push-to-front
Add push to front of rate limit queue.
2021-09-30 10:44:14 +01:00
Nick O'Leary
aa5fad6628
Add deep copy option to Change node 'set' action 2021-09-30 09:49:51 +01:00
Nick O'Leary
1931395fdb
Add basic link-call/return tests 2021-09-29 13:49:55 +01:00
Nick O'Leary
85820c571d
Add unit tests for allowUpdate settings 2021-09-14 10:50:26 +01:00
Casey Wilkes
d32636ed6b Tweak theme tests for tabicon colour config 2021-09-10 23:16:42 +12:00
Hiroyasu Nishiyama
6aecc3915c add support of environtment variable for tab & group 2021-08-19 21:15:13 +09:00
Nick O'Leary
40233c7702
Fix regression in Join node when manual joining array with msg.parts present
Fixes #3096
2021-07-30 13:17:05 +01:00
Nick O'Leary
6364e00202
Merge pull request #3092 from hardillb/http-req-ca-fix
Copy tls.cert to tls.certificate for GOT
2021-07-28 10:05:19 +01:00
Ben Hardill
a76c6f86c6
Add Testcase & Fix typo 2021-07-28 08:52:35 +01:00
Nick O'Leary
f1775d4fd1
Handle partially encoded url query strings in request node 2021-07-26 14:21:52 +01:00
Ben Hardill
26087f8dc7
Fix support for supplied CA certs 2021-07-26 10:25:06 +01:00
Nick O'Leary
c5892fc17e
Fix HTML parsing when body is included in the select tag
Fixes #3079
2021-07-23 10:09:00 +01:00
Nick O'Leary
6e69cfbca4
Preserve case of user-provided http headers in request node
Fixes #3081
2021-07-23 09:55:32 +01:00
Nick O'Leary
36e83d628e
Add unit tests for HTTP Request encodeURI and error response 2021-07-23 00:10:17 +01:00
Dave Conway-Jones
4d26b806dd
delay - add test for push toFront and flush=1 2021-07-16 11:38:06 +01:00
Dave Conway-Jones
a2b95dbb39
delay node - change lifo property to toFront
add info to sidebar
add tests
2021-07-16 11:31:21 +01:00
Nick O'Leary
be9f9e7b0c
Change default functionExternalModules test 2021-07-15 10:13:21 +01:00
Nick O'Leary
eb4625a0b9
Merge pull request #3064 from node-red/revert-external-modules-dir
Move externalModules back into the user dir
2021-07-15 09:56:23 +01:00
Nick O'Leary
5bfb01254b
Add unit tests for externalModules.import 2021-07-15 09:52:53 +01:00
Nick O'Leary
bb80fa4a2d
Fix externalModules tests 2021-07-14 23:38:46 +01:00
Nick O'Leary
65081767bf
Fix externalModules tests 2021-07-13 11:44:12 +01:00
Dave Conway-Jones
ea11aa7a0d
add some part flush tests 2021-07-08 13:51:37 +01:00
Dave Conway-Jones
41c8ca8ab4
Delay node updates to added flush control for queuing 2021-07-08 12:13:23 +01:00
Nick O'Leary
b2f5a259ab
Fix exec node test for gh-actions
The node adds `shell` to `execOpts` if `/bin/bash` exists. Clearly it
has not existed in Travis or running locally - but it does exist
on gh-action runner, so the test was failing.
2021-07-02 10:15:44 +01:00
Nick O'Leary
c8a0d3c10d
Add error handling to exec test 2021-07-02 10:09:00 +01:00
Nick O'Leary
42992c64ec
Merge branch 'pr_3026' into dev 2021-07-02 09:22:35 +01:00
Nick O'Leary
2ce0e38827
Merge pull request #3040 from node-red/map-set-debug
Add support for Map/Set property types on Debug
2021-06-29 14:08:29 +01:00
Nick O'Leary
48ac50e1c9
Add support for Map/Set property types on Debug 2021-06-29 11:09:30 +01:00
Dave Conway-Jones
6aac44db14
Add option for file-in node to include all properties (default off)
and add test
2021-06-25 14:39:18 +01:00
Nathanaël Lécaudé
7ae48d7390 exec: solidify tests 2021-06-16 17:38:34 -04:00
Nathanaël Lécaudé
2f0631809d exec node: modify test 2021-06-16 17:09:21 -04:00
Ben Hardill
553bec1a1f
Add testcase 2021-06-11 14:34:16 +01:00
Nick O'Leary
4acb66fb7a
Merge branch 'master' into dev 2021-06-10 16:06:30 +01:00
Dave Conway-Jones
b73efe6bb4
Ensure CSV node tries to parse number when set to do so (trim whitespace) 2021-06-10 14:55:47 +01:00
Nick O'Leary
133df75bd4
Merge branch 'dev' into get-got 2021-06-09 09:59:23 +01:00
Ben Hardill
d5c5738aab
Fix proxy authentication problem & reinstate tests
Down to only 2 of the previous tests not working
2021-06-08 14:22:20 +01:00
Ben Hardill
090852b72b
Revet changes to /proxyAuthneticate
This end point is currently not hit
2021-06-08 12:06:18 +01:00
Ben Hardill
4e8c0573c4
Re-enable as many http-request proxy tests as possible 2021-06-08 11:46:54 +01:00
Nick O'Leary
ce905ba2c4
Merge branch 'master' into dev 2021-06-08 11:44:31 +01:00
Nick O'Leary
7bf938901a
Merge branch 'pr_2952' into dev 2021-06-08 11:09:56 +01:00
Nick O'Leary
4edea59ab1
Merge branch 'pr_2990' into dev 2021-06-08 10:56:57 +01:00
Ben Hardill
17a139f27f
Start to add HTTP-PROXY tests back in 2021-06-08 10:30:24 +01:00
Nick O'Leary
dbbdd3f799
Update to latest cheerio module 2021-06-08 09:31:27 +01:00
Ben Hardill
bd1943626b
Add more comment 2021-06-07 16:00:07 +01:00
Ben Hardill
33f8c9747d
Comment out HTTP Proxy tests
These have been removed because the mock proxy doesn't
support using the HTTP CONNECT verb and the new Got based
http-request node only uses CONNET for proxied content
2021-06-07 13:00:02 +01:00
Nick O'Leary
7c02e4d66a
Merge branch 'master' into dev 2021-06-02 15:40:56 +01:00
Nick O'Leary
711794cfe1
Merge pull request #2993 from Steve-Mcl/master
ensure context get/set key is a string
2021-06-02 15:20:25 +01:00
Nick O'Leary
3d405f8c63
Merge pull request #2969 from node-red/ajv-update
Update ajv to 8.2.0 - drop support for JSON-Schema draft-04
2021-05-27 12:17:51 +01:00
Steve-Mcl
a92f0c4c6e fix context key validation + add tests
- adds a helper function validateContextKey to keep it DRY
- adds tests ensure key of null "" 1 {} [] [""] [1] [{}] all throw error
2021-05-26 13:04:09 +01:00
Hiroyasu Nishiyama
bb1b3727cb add test case 2021-05-23 10:42:28 +09:00
Steve-Mcl
845567d1ba add 2 tests for user inject values 2021-05-20 22:53:32 +01:00
Nick O'Leary
74628b7034
Update debug tests to handle compact comms format 2021-05-13 14:18:11 +01:00
Nick O'Leary
71ba73b38f
Merge branch 'master' into dev 2021-05-04 11:19:05 +01:00
Nick O'Leary
00caa13a12
Update externalModules_spec to handle variable npm args length 2021-04-29 11:04:19 +01:00
Nick O'Leary
cfc0135e86
Update ajv to 8.2.0 - drop support for JSON-Schema draft-04 2021-04-29 10:48:26 +01:00
Nick O'Leary
7df1a03b4b
Handle subflow modules that contain subflows 2021-04-28 21:50:00 +01:00
Hiroyasu Nishiyama
70433f3d05 fix grunt fail on exec node test 2021-04-28 21:40:17 +09:00
Nick O'Leary
4133f9c56f
Merge pull request #2936 from node-red/npm-install-hooks
Add pre/postInstall hooks to npm install handling
2021-04-27 10:57:14 +01:00
Nick O'Leary
53055064e1
Merge pull request #2932 from node-red/file-cwd-setting
File node: Add fileWorkingDirectory to customise how relative paths are resolved
2021-04-27 10:49:02 +01:00
Nick O'Leary
f7210effec
Rework hooks structure to be a linkedlist
Allows for safe removal of hooks whilst they are being invoked
2021-04-26 21:14:42 +01:00
Dave Conway-Jones
f8abf9fce1
add another test to csv 2021-04-25 08:53:18 +01:00
Nick O'Leary
e23f20227a
Initial migration from request to got for http-request node 2021-04-23 14:19:15 +01:00
Dave Conway-Jones
9f1deb0c36
CSV Add couple more special character tests just to make sure 2021-04-23 11:19:23 +01:00
Dave Conway-Jones
4cebbf8d22
Fix CSV handling of special chars as separators
(ie escape regex special chars)
and add tests
to close #2950
2021-04-23 10:47:23 +01:00
Kazuhito Yokoi
a20049c82a
Delay node enhancements (#2294)
* Remove unused messages in message catalog

* Support msg.rate in delay node

* Support nodeMessageBufferMaxLength in delay node

* Add logging function for queue size

* Support msg.nodeMessageBufferMaxLength

* Revert "Support msg.nodeMessageBufferMaxLength"

This reverts commit cc72f892f7.

* Improve logging function for delay node

* Add support for Messaging API to delay node

* Add documentation about msg.rate in delay node

* Add test cases for msg.rate in delay node

Co-authored-by: Dave Conway-Jones <dceejay@users.noreply.github.com>
2021-04-22 09:01:28 +01:00
Nick O'Leary
250005ad16
Allow npm install args to be customised by preInstall trigger 2021-04-20 22:55:06 +01:00
Nick O'Leary
b4a03a56b4
Allow preInstall hook to return false to skip npm install 2021-04-19 20:29:30 +01:00
Dave Conway-Jones
73063df11b
Pull in RBE node and push out tail 2021-04-19 13:09:13 +01:00
Nick O'Leary
d2432716ea
Fix hook requires in unit tests 2021-04-15 15:30:02 +01:00
Nick O'Leary
52ef85cba3
Update test for latest sinon 2021-04-15 15:15:52 +01:00
Nick O'Leary
8140057bea
Add pre/postInstall hooks to module install path 2021-04-15 15:12:40 +01:00
Nick O'Leary
22df59e229
Update hooks api to support promise api 2021-04-15 15:12:35 +01:00
Nick O'Leary
ed351eee54
Move hooks to util package 2021-04-15 15:12:30 +01:00
Nick O'Leary
aac2a8f830
File node: Add fileWorkingDirectory to customise how relative paths are resolved 2021-04-12 18:00:58 +01:00
Dave Conway-Jones
858b3d640a
fix CSV parsing with other than , separator
(and joining as well...
and add tests
to close #2925
2021-04-10 22:17:31 +01:00
Nick O'Leary
877c463494
Update to latest sinon 2021-04-09 11:22:57 +01:00
Kristian Heljas
7b8ed487e9
Function node: add node.outputCount property to sandbox (#2918)
* Function node: add `node.outputs` property to sandbox

https://discourse.nodered.org/t/expose-configured-output-count-to-function-node-i-can-pr/43848

* style: indetation for function node sanbox code

I guess this was unintentionally unindented in d51aefa156 (diff-24cd715c3b7405ea194bfdc0dc2a350ceb2f5d18696b8163c3e40105b981a666)

* Function node: tests for accessing node properties

consistently tests that `node.id`, `node.name` and `node.outputs`
are available in `init()`, `func()` and `finalize()` methods.

* Function node: rename `node.outputs` to `node.outputCount`

https://discourse.nodered.org/t/expose-configured-output-count-to-function-node-i-can-pr/43848/9?u=kristian
2021-04-08 14:52:02 +01:00
Nick O'Leary
f0f2eefb59
Merge branch 'pr_2908' into dev 2021-03-31 23:50:30 +01:00
Nick O'Leary
bdb548ffdc
Exec node: remove addpayValue and reuse addpay to track appending property 2021-03-31 23:50:00 +01:00
Nick O'Leary
d555fcf7bd
Merge pull request #2903 from node-red/plugin-resources
Allow module to provide resources and automatically expose them
2021-03-30 22:50:36 +01:00
Nick O'Leary
8da00c0872
Fix Switch node handling of hasKey rule when property is undefined 2021-03-30 21:37:39 +01:00
Kazuhito Yokoi
cb72d5100e Remove type for typedInput in exec node 2021-03-22 20:24:12 +09:00
Kazuhito Yokoi
f103533852 Support typedInput in msg.payload field of exec node 2021-03-22 16:19:55 +09:00
Nick O'Leary
8543613563
Allow module to provide resources and automatically expose them 2021-03-15 21:06:10 +00:00
Dave Conway-Jones
df90e3414d
CSV better handling of messages with incoming parts - to create array output
and add tests (apologies for the massive reformat of test file) - but honestly there are two new tests
2021-03-11 12:47:54 +00:00
Dave Conway-Jones
16b9abbe92
redo CSV fix for commas in header template 2021-03-11 09:34:30 +00:00
Nick O'Leary
99a9e3a91b
Fix handling encrypted creds on /flows api 2021-03-06 20:27:51 +00:00
Nick O'Leary
0566a2d9b1
Fix function node tests use of RED.settings 2021-03-02 00:12:41 +00:00
Nick O'Leary
3d23d1de4f
Merge pull request #2873 from node-red/function-modules
Function node external modules
2021-03-01 21:35:31 +00:00
Nick O'Leary
c9c5f7f088
Fix functionExternalModules tests 2021-03-01 21:34:37 +00:00
Dave Conway-Jones
fc709ba266
revert CSV node to commas in headers fix level 2021-02-26 14:34:38 +00:00
Nick O'Leary
0dc4440a99
Merge branch 'master' into dev 2021-02-25 17:56:01 +00:00