shunter
Version:
A Node.js application built to read JSON and translate it into HTML
18 lines (14 loc) • 469 B
JavaScript
;
var assert = require('proclaim');
var helper = require('../../helpers/template.js')();
describe('Dust Filter: amp', function() {
it('Should safely html-escape ampersands', function(done) {
helper.render('{test1|s|amp} {test2|s|amp}', {
test1: '<p>A & B</p>',
test2: '<p>A > & 舒 B &</p>'
}, function(err, dom, str) {
assert.strictEqual(str, '<p>A & B</p> <p>A > & 舒 B &</p>');
done();
});
});
});