Skip to content

Commit

Permalink
Include reference to issue #680
Browse files Browse the repository at this point in the history
  • Loading branch information
zachleat committed Jul 11, 2020
1 parent dc51a11 commit 6c8addf
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions test/TemplateRenderLiquidTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -977,42 +977,42 @@ test("Liquid Render a false #1069", async t => {
t.is(await fn({ falseValue: false }), "false");
});

test("Liquid Render Square Brackets dash single quotes", async t => {
test("Liquid Render Square Brackets #680 dash single quotes", async t => {
let fn = await new TemplateRender("liquid").getCompiledTemplate(
"<p>{{ test['hey-a'] }}</p>"
);
t.is(await fn({ test: { "hey-a": 1 } }), "<p>1</p>");
});

test.skip("Liquid Render Square Brackets dash single quotes spaces", async t => {
test.skip("Liquid Render Square Brackets #680 dash single quotes spaces", async t => {
let fn = await new TemplateRender("liquid").getCompiledTemplate(
"<p>{{ test[ 'hey-a' ] }}</p>"
);
t.is(await fn({ test: { "hey-a": 1 } }), "<p>1</p>");
});

test("Liquid Render Square Brackets dash double quotes", async t => {
test("Liquid Render Square Brackets #680 dash double quotes", async t => {
let fn = await new TemplateRender("liquid").getCompiledTemplate(
'<p>{{ test["hey-a"] }}</p>'
);
t.is(await fn({ test: { "hey-a": 1 } }), "<p>1</p>");
});

test.skip("Liquid Render Square Brackets dash double quotes spaces", async t => {
test.skip("Liquid Render Square Brackets #680 dash double quotes spaces", async t => {
let fn = await new TemplateRender("liquid").getCompiledTemplate(
'<p>{{ test[ "hey-a" ] }}</p>'
);
t.is(await fn({ test: { "hey-a": 1 } }), "<p>1</p>");
});

test("Liquid Render Square Brackets variable reference", async t => {
test("Liquid Render Square Brackets #680 variable reference", async t => {
let fn = await new TemplateRender("liquid").getCompiledTemplate(
"<p>{{ test[ref] }}</p>"
);
t.is(await fn({ test: { "hey-a": 1 }, ref: "hey-a" }), "<p>1</p>");
});

test.skip("Liquid Render Square Brackets variable reference array", async t => {
test.skip("Liquid Render Square Brackets #680 variable reference array", async t => {
let fn = await new TemplateRender("liquid").getCompiledTemplate(
"<p>{{ test[ref[0]] }}</p>"
);
Expand Down

0 comments on commit 6c8addf

Please sign in to comment.