瀏覽代碼

Assert `null` value render

It was not being asserted anywhere else, and I was suspecting that
PR #552 was changing current (and correct) behaviour.
tags/v2.3.0
David da Silva 10 年之前
父節點
當前提交
7e83df9b05
共有 4 個文件被更改,包括 5 次插入3 次删除
  1. +1
    -0
      test/_files/escaped.js
  2. +1
    -1
      test/_files/escaped.mustache
  3. +2
    -1
      test/_files/unescaped.js
  4. +1
    -1
      test/_files/unescaped.mustache

+ 1
- 0
test/_files/escaped.js 查看文件

@@ -2,5 +2,6 @@
title: function () { title: function () {
return "Bear > Shark"; return "Bear > Shark";
}, },
symbol: null,
entities: "&quot; \"'<>`=/" entities: "&quot; \"'<>`=/"
}) })

+ 1
- 1
test/_files/escaped.mustache 查看文件

@@ -1,2 +1,2 @@
<h1>{{title}}</h1>
<h1>{{title}}{{symbol}}</h1>
And even {{entities}}, but not {{{entities}}}. And even {{entities}}, but not {{{entities}}}.

+ 2
- 1
test/_files/unescaped.js 查看文件

@@ -1,5 +1,6 @@
({ ({
title: function () { title: function () {
return "Bear > Shark"; return "Bear > Shark";
}
},
symbol: null
}) })

+ 1
- 1
test/_files/unescaped.mustache 查看文件

@@ -1 +1 @@
<h1>{{{title}}}</h1>
<h1>{{{title}}}{{{symbol}}}</h1>

Loading…
取消
儲存