From f5afbc90a4a6b0fec64a35581e6d4383253bd5aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samy=20Pess=C3=A9?= Date: Thu, 17 Sep 2015 11:21:55 +0200 Subject: [PATCH] Add more tests for blocks args/kwargs --- test/plugins.js | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/test/plugins.js b/test/plugins.js index e6df38971..797fc38e4 100644 --- a/test/plugins.js +++ b/test/plugins.js @@ -192,7 +192,21 @@ describe("Plugins", function () { }); }); - it("should correctly extend template blocks with arguments", function() { + it("should correctly extend template blocks with arguments (1)", function() { + return testTpl("{% test5args \"a\" %}{% endtest5args %}") + .then(function(content) { + content.should.equal("test5atest5"); + }); + }); + + it("should correctly extend template blocks with arguments (2)", function() { + return testTpl("{% test5args 'a', 'b' %}{% endtest5args %}") + .then(function(content) { + content.should.equal("test5a,btest5"); + }); + }); + + it("should correctly extend template blocks with arguments (3)", function() { return testTpl("{% test5args 'a', 'b', 'c' %}{% endtest5args %}") .then(function(content) { content.should.equal("test5a,b,ctest5");