Skip to content

Commit

Permalink
Improved "Section - No Re-interpolation" test:
Browse files Browse the repository at this point in the history
This change strengthens the test case.  In the previous version, if
the string "{{.}}" was on the top of the context stack, the test could
conceivably have passed with certain versions of bad code.
  • Loading branch information
cjerdonek committed Apr 29, 2012
1 parent f5b2e9d commit 266747a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions specs/~lambdas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,11 +123,11 @@ tests:
desc: The lambda return value should not be re-interpolated.
data:
planet: "Earth"
dot: "{{.}}"
dot: "#{{.}}#"
lambda: !code
python: 'lambda text: "{{%s}}" % text'
python: 'lambda text: "~{{%s}}~" % text'
template: "<{{#planet}}{{#lambda}}dot{{/lambda}}{{/planet}}>"
expected: "<{{.}}>"
expected: "<~#{{.}}#~>"

- name: Section - Alternate Delimiters
desc: Lambdas used for sections should parse with the current delimiters.
Expand Down

0 comments on commit 266747a

Please sign in to comment.