From 5e19b3049bf4e688d6aaab150883039f341049f6 Mon Sep 17 00:00:00 2001 From: David da Silva Date: Tue, 15 Mar 2016 18:26:07 +0100 Subject: [PATCH 1/2] Add consistent indentation in null_lookup_object.js test file Either vim or git was going crazy with the indentation when I tried improving the test via changing one of the lines, so I linted it all together. --- test/_files/null_lookup_object.js | 54 +++++++++++++++---------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/test/_files/null_lookup_object.js b/test/_files/null_lookup_object.js index 0f82480..2f2efd7 100644 --- a/test/_files/null_lookup_object.js +++ b/test/_files/null_lookup_object.js @@ -1,31 +1,31 @@ ({ - "name": "David", - "twitter": "@dasilvacontin", - "fobject": [ - { - "name": "Flor", - "twitter": "@florrts" - }, - { - "name": "Miquel", - "twitter": null - }, - { - "name": "Chris", - "twitter": undefined - } - ], - "favorites": { - "color": "blue", - "president": "Bush", - "show": "Futurama" + "name": "David", + "twitter": "@dasilvacontin", + "fobject": [ + { + "name": "Flor", + "twitter": "@florrts" + }, + { + "name": "Miquel", + "twitter": null }, - "mascot": { - "name": "Squid", - "favorites": { - "color": "orange", - "president": undefined, - "show": null - } + { + "name": "Chris", + "twitter": undefined + } + ], + "favorites": { + "color": "blue", + "president": "Bush", + "show": "Futurama" + }, + "mascot": { + "name": "Squid", + "favorites": { + "color": "orange", + "president": undefined, + "show": null } + } }) From 7e83df9b0599cadbe33e65d632d1604847e6716f Mon Sep 17 00:00:00 2001 From: David da Silva Date: Tue, 15 Mar 2016 18:40:20 +0100 Subject: [PATCH 2/2] Assert `null` value render It was not being asserted anywhere else, and I was suspecting that PR #552 was changing current (and correct) behaviour. --- test/_files/escaped.js | 1 + test/_files/escaped.mustache | 2 +- test/_files/unescaped.js | 3 ++- test/_files/unescaped.mustache | 2 +- 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/test/_files/escaped.js b/test/_files/escaped.js index e600959..4276a39 100644 --- a/test/_files/escaped.js +++ b/test/_files/escaped.js @@ -2,5 +2,6 @@ title: function () { return "Bear > Shark"; }, + symbol: null, entities: "" \"'<>`=/" }) diff --git a/test/_files/escaped.mustache b/test/_files/escaped.mustache index 93e800b..5c44268 100644 --- a/test/_files/escaped.mustache +++ b/test/_files/escaped.mustache @@ -1,2 +1,2 @@ -

{{title}}

+

{{title}}{{symbol}}

And even {{entities}}, but not {{{entities}}}. diff --git a/test/_files/unescaped.js b/test/_files/unescaped.js index b6d064f..0659b69 100644 --- a/test/_files/unescaped.js +++ b/test/_files/unescaped.js @@ -1,5 +1,6 @@ ({ title: function () { return "Bear > Shark"; - } + }, + symbol: null }) diff --git a/test/_files/unescaped.mustache b/test/_files/unescaped.mustache index 6b07d7b..1a27f58 100644 --- a/test/_files/unescaped.mustache +++ b/test/_files/unescaped.mustache @@ -1 +1 @@ -

{{{title}}}

+

{{{title}}}{{{symbol}}}