mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Revert runtime/util
This commit is contained in:
@@ -153,9 +153,11 @@ describe("red/util", function() {
|
||||
var v = util.getMessageProperty({a:"foo"},"msg.b");
|
||||
should.not.exist(v);
|
||||
});
|
||||
it('should return undefined if property parent does not exist', function() {
|
||||
var v = util.getMessageProperty({a:"foo"},"msg.a.b.c");
|
||||
should.not.exist(v);
|
||||
it('should throw error if property parent does not exist', function() {
|
||||
/*jshint immed: false */
|
||||
(function() {
|
||||
util.getMessageProperty({a:"foo"},"msg.a.b.c");
|
||||
}).should.throw();
|
||||
});
|
||||
it('retrieves a property with array syntax', function() {
|
||||
var v = util.getMessageProperty({a:["foo","bar"]},"msg.a[0]");
|
||||
|
Reference in New Issue
Block a user