Commit Graph

15 Commits (1bc75374dc9da19106c0b8aa33a9683dd4b51a50)

Author SHA1 Message Date
James Cammarata 86de1429e5 Cleaning up FIXMEs 10 years ago
Brian Coca b6d6c2e4db corrected all missing paths changes 10 years ago
Marius Gedminas f91b28ef23 Fix safe_eval() of set literals
There was code to support set literals (on Python 2.7 and newer), but it
was buggy: SAFE_NODES.union() doesn't modify SAFE_NODES in place,
instead it returns a new set object that is then silently discarded.

I added a unit test and fixed the code.  I also changed the version
check to use sys.version_tuple instead of a string comparison, for
consistency with the subsequent Python 3.4 version check that I added in
the previous commit.
10 years ago
Toshio Kuratomi e218bf8da9 Do not escape backslashes when processing a template file.
Fixes #12198
Fixes #12241
10 years ago
Toshio Kuratomi 1b64702b9a Fix templar unittests for change in preserve_trailing_newline parameter's default value 10 years ago
James Cammarata 45aac6a739 Adding unit tests for safe_eval 10 years ago
Toshio Kuratomi 9ecfc30f9a * Mark all strings as unicode -- shouldn't matter for this dataset but
ansible is passing unicode arond internally so we should test the same
  data.
* Add a zero length test for _count_newlines and fix the zero newlines
  test to have no newlines.
10 years ago
Toshio Kuratomi 417bf1c805 Unittest the _count_trailing_newlines function 10 years ago
Toshio Kuratomi 7f5080f64a Fix backslash escaping inside of jinja2 expressions
Fixes #11891
10 years ago
Brian Coca 43bf9c86d8 fixed typo 10 years ago
Brian Coca d38bb4152d fixed test to match new exception class used 10 years ago
Brian Coca e9cf67004b updated fail_on_undefined test to new function signatures 11 years ago
James Cammarata 398b1d3e60 Cleaning up template test syntax a bit 11 years ago
James Cammarata 9aa8676bdd More template unit tests for v2 11 years ago
James Cammarata 23cd3294d0 Starting to add v2 tests for template 11 years ago