@ministryofjustice/fb-nunjucks-helpers
Advanced tools
Comparing version 0.0.12 to 0.0.13
@@ -31,3 +31,3 @@ const test = require('tape') | ||
const output = nunjucksEnv.renderString(blockTemplate).trim() | ||
t.equals(output, '<div class="govuk-form-group fb-block-block" data-block-id="blockId" data-block-type="block">\nblockHeadingValue\n</div>', 'it should render the corresponding block') | ||
t.equals(output, '<div class="fb-block fb-block-block govuk-form-group" data-block-id="blockId" data-block-type="block">\nblockHeadingValue\n</div>', 'it should render the corresponding block') | ||
@@ -47,3 +47,3 @@ const anotherId = 'anotherBlockId' | ||
const nestedOutput = nunjucksEnv.renderString(nestedTemplate).trim() | ||
t.equals(nestedOutput, '<div class="govuk-form-group fb-block-anotherblock" data-block-id="anotherBlockId" data-block-type="anotherblock">\nblockTitleValue\n<div class="govuk-form-group fb-block-block" data-block-id="innerBlockId" data-block-type="block">\ninnerBlockHeadingValue\n</div>\n</div>', 'it should render nested callBlock') | ||
t.equals(nestedOutput, '<div class="fb-block fb-block-anotherblock govuk-form-group" data-block-id="anotherBlockId" data-block-type="anotherblock">\nblockTitleValue\n<div class="fb-block fb-block-block govuk-form-group" data-block-id="innerBlockId" data-block-type="block">\ninnerBlockHeadingValue\n</div>\n</div>', 'it should render nested callBlock') | ||
@@ -73,5 +73,5 @@ t.end() | ||
const output = nunjucksEnv.renderString(blocksTemplate).trim() | ||
t.equals(output, '<div class="govuk-form-group fb-block-anotherblock" data-block-id="blockId" data-block-type="anotherblock">\nblockTitleValue\n<div class="govuk-form-group fb-block-block" data-block-id="innerBlockId" data-block-type="block">\ninnerBlockHeadingValue\n</div>\n</div><div class="govuk-form-group fb-block-block" data-block-id="blockId" data-block-type="block">\nblockHeadingValue\n</div>', 'it should render nested callBlock') | ||
t.equals(output, '<div class="fb-block fb-block-anotherblock govuk-form-group" data-block-id="blockId" data-block-type="anotherblock">\nblockTitleValue\n<div class="fb-block fb-block-block govuk-form-group" data-block-id="innerBlockId" data-block-type="block">\ninnerBlockHeadingValue\n</div>\n</div><div class="fb-block fb-block-block govuk-form-group" data-block-id="blockId" data-block-type="block">\nblockHeadingValue\n</div>', 'it should render nested callBlock') | ||
t.end() | ||
}) |
{ | ||
"name": "@ministryofjustice/fb-nunjucks-helpers", | ||
"version": "0.0.12", | ||
"version": "0.0.13", | ||
"description": "Form Builder Nunjucks helpers", | ||
@@ -5,0 +5,0 @@ "main": "lib/fb-nunjucks-helpers.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
29481