summaryrefslogtreecommitdiff
path: root/cheetah/Tests
Commit message (Collapse)AuthorAgeFilesLines
* Fix EOL tests for Python 2.7R. Tyler Croy2010-12-121-3/+3
| | | | | | Patch from: Mike Bonnet <mikeb@redhat.com> Change-Id: I3a3a3e57c1c94cac0ee020e41882b86dc9a4d4be
* Added test and fix for segfault in namemapper where exception is thrown by ↵Jon Siddle2010-09-151-0/+13
| | | | __getattr__.
* Properly generate a PYTHONPATH and locate the cheetah executable for ↵R. Tyler Ballance2010-03-211-6/+12
| | | | | | | | CheetahWrapper tests On FreeBSD particularly, the tempfile.mktemp() heavily sandboxes the process into /tmp/ somewhere. Finding absolute paths to the cheetah process and the Cheetah/ directory is necessary to properly run the tests
* Find the #encoding directive even if it's after a comment (for example)R. Tyler Ballance2010-01-271-0/+6
| | | | | | | Added a test and applied Juan's patch, everything seems to check out alright with it Reported-by: Juan Fiol <fiolj@yahoo.com>
* Import __builtin__ in generated template code in a compatible way with 2 and 3R. Tyler Ballance2010-01-031-2/+12
|
* Remove references to the `new` moduleR. Tyler Ballance2009-12-271-1/+0
|
* NameMapperTest.failureException cannot be a tupleR. Tyler Ballance2009-12-271-1/+1
|
* Add regression test for dynamically compiled subclasses of TemplateR. Tyler Ballance2009-12-261-0/+10
|
* Add a test to verify the use of getVar and write inside of a PSPR. Tyler Ballance2009-12-191-1/+17
|
* Refactor the InlineSpanishTest to better clarify a success/failure scenarioR. Tyler Ballance2009-12-161-5/+16
|
* Add a test to verify escaped entities in #raw blocksR. Tyler Ballance2009-12-151-0/+6
| | | | Related to 0cc9f78 and 70c9bd4
* Add another unicode testR. Tyler Ballance2009-12-141-0/+28
| | | | | | | This is based off an IRC conversation in #cheetah which I've honestly forgotten what the bug was when I wrote the test case. Pech gehabt.
* Correct relative imports of test modulesR. Tyler Ballance2009-11-181-11/+11
|
* Add DirectiveAnalyzer tests to suiteR. Tyler Ballance2009-11-181-0/+2
|
* Introduce the DirectiveAnalyzer for processing templates for directive usageR. Tyler Ballance2009-11-161-0/+29
| | | | | Hoping to form this into a fully-fledged reporting tool so I can gauge usage of directives to start cutting some out.
* Clean up a swath of fixes suggested by 2to3R. Tyler Ballance2009-11-165-79/+79
| | | | | Fixes from 2to3 include: xrange, ws_comma, repr, reduce, raise, idioms, has_key, future, filter, exec, callable, apply
* Refactor Cheetah.Parser.ArgListR. Tyler Ballance2009-11-162-0/+51
| | | | | | Added a test for ArgList as well; a large amount of code in Cheetah.Parser could do well to be cleaned up, but perhaps another day.
* Refactor CheetahWrapper tests to locate my local cheetah/cheetah-compile in ↵R. Tyler Ballance2009-11-161-5/+22
| | | | | | | my PATH Adding the "buildandrun" shortcut script so to easily rerun the full test suite locally; usage: ./buildandrun cheetah/Tests/Test.py
* Refactor usage of the "types" module out, per 2to3 -f typesR. Tyler Ballance2009-11-166-1139/+27
| | | | | Left out cheetah/Template.py which will need to be refactored a bit more aggressively, particularly in Template.compile()
* Refactor raw print statements in accordance with 2to3R. Tyler Ballance2009-11-168-15/+15
| | | | | Removed prints in a couple places entirely, some of this code should likely use the `logging` module instead
* Add --quiet option and use it to suppress messages from the Unicode testsJames Abbatiello2009-11-161-1/+1
|
* Add Template.__unicode__() to return unicode() objects, while ↵R. Tyler Ballance2009-10-181-0/+16
| | | | | | | | | | | | | | Template.__str__() returns encoded str() objects Per my discussion in #cheetah on IRC with mikeb@ regarding the following issue: https://bugzilla.redhat.com/show_bug.cgi?id=529332 This, in addition to recent patches to cheetah/DummyTransaction.py should alleviate migration issues for users still passing a mishmash of unicode()/str() objects into Templates. __str__() should return a str() object, whereas __unicode__() should return a unicode() object. No-op the EncodeUnicode filter when it encounters a unicode() object.
* Add a simple test to help judge perfomance of DummyTransaction.write()R. Tyler Ballance2009-10-141-0/+17
|
* Correctly use cStringIO which only deals in bytestrings.R. Tyler Ballance2009-10-141-3/+2
| | | | | | | I'm uncertain if there's any lossiness in encoding a unicode() object 'utf-8' prior to writing to the stream, but this does appear to inadvertantly fix another issue we had with mixing UTF-8 encoded strings and unicode() objects when filling a template.
* Update the printing of the Performance testsR. Tyler Ballance2009-10-121-5/+9
| | | | | I want to print out the directories to ensure that I'm actually testing the code I think I'm testing (*facepalm*)
* Swap out statprof for hotshot profiling with these basic Performance test casesR. Tyler Ballance2009-10-121-10/+11
|
* implement the popen2.Popen4 interface using the subprocess.Popen backend, to ↵Mike Bonnet2009-10-121-2/+13
| | | | | | avoid DeprecationWarnings when running the tests on python >= 2.6 Finally got tired of 'em. :)
* Don't use function decorator syntax for compatibility with Python 2.3v2.2.2James Abbatiello2009-09-141-1/+2
|
* Nuke the VerifyType tests since they're largely unnecessary nowR. Tyler Ballance2009-09-141-2/+0
|
* Prune a leftover print statementR. Tyler Ballance2009-09-101-1/+0
|
* Ensure all the EOL tests are run, as well as Filters testsR. Tyler Ballance2009-09-102-20/+25
|
* Remove references to unittest_local_copy which is quite old and causing problemsR. Tyler Ballance2009-09-107-11/+7
|
* Add the VerifyType tests to the runnerR. Tyler Ballance2009-09-013-3/+380
|
* Add Cheps.py test moduleR. Tyler Ballance2009-08-311-0/+39
|
* Add the CHEP related test module in hereR. Tyler Ballance2009-08-281-0/+2
|
* Remove the VerifyType module from Test.py, I think I left this on another ↵R. Tyler Ballance2009-08-141-2/+0
| | | | machine
* Merge branch 'next' into performanceR. Tyler Ballance2009-08-141-4/+2
| | | | | | | | | | | Left some rename conflicts partially unresolved, need to move src/c/ to cheetah/c/ in the next commit Conflicts: SetupConfig.py cheetah/_namemapper.c src/_namemapper.c src/c/_namemapper.c
* Rename the root package to "cheetah" instead of "src" to follow more ↵R. Tyler Ballance2009-07-1611-0/+6559
conventional python package naming