Skip to content

Commit

Permalink
Merge pull request #427 from kethinov/test-for-426
Browse files Browse the repository at this point in the history
Test for #426
  • Loading branch information
kethinov authored Oct 7, 2020
2 parents 89e8db7 + 8c64800 commit a935020
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/misc.js
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,11 @@ describe('Misc', function () {
done()
})

it.skip('should not render Teddy code in server-side comments in loops (misc/serverSideCommentsWithTeddyCode.html)', function (done) {
assert.equalIgnoreSpaces(teddy.render('misc/serverSideCommentsWithTeddyCode.html', model), '<div><p>test</p><p>test</p><p>test</p><p>test</p><p>test</p><p>test</p></div>')
done()
})

it('should execute render callback function for errors and non errors', function (done) {
teddy.setMaxPasses(100)
teddy.setVerbosity(3)
Expand Down
14 changes: 14 additions & 0 deletions test/templates/misc/serverSideCommentsWithTeddyCode.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{!
should not render Teddy code in server-side comments in loops
!}

<div>
<loop through='names' key='name' val='description'>
<p>test</p>
{!
should not render this loop
<loop through='objects' key='k' val='v'>
!}
<p>test</p>
</loop>
</div>

0 comments on commit a935020

Please sign in to comment.