Skip to content

Commit

Permalink
Correct failing test due to the #call kwarg dictionary being generate…
Browse files Browse the repository at this point in the history
…d with unicode keys

Test failures like this:
	Traceback (most recent call last):
	  File "/home/tyler/source/github/cheetah/src/Tests/SyntaxAndOutput.py", line 1173, in test4
		"1235 FOO - upper")
	  File "/home/tyler/source/github/cheetah/src/Tests/SyntaxAndOutput.py", line 194, in verify
		output = templateObj.respond() # rather than __str__, because of unicode
	  File "cheetah_DynamicallyCompiledCheetahTemplate_1240479809_54_46184.py", line 137, in respond
	TypeError: meth() keywords must be strings

Should now be resolved.

mantis #15

Signed-off-by: R. Tyler Ballance <tyler@slide.com>
  • Loading branch information
R. Tyler Ballance committed May 12, 2009
1 parent aacd468 commit b7c93f8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 12 deletions.
1 change: 1 addition & 0 deletions src/Compiler.py
Expand Up @@ -834,6 +834,7 @@ class CallDetails(object):

def setCallArg(self, argName, lineCol):
ID, callDetails = self._callRegionsStack[-1]
argName = str(argName)
if callDetails.usesKeywordArgs:
self._endCallArg()
else:
Expand Down
17 changes: 5 additions & 12 deletions src/Tests/SyntaxAndOutput.py
@@ -1,24 +1,16 @@
#!/usr/bin/env python
# -*- coding: latin-1 -*-
# $Id: SyntaxAndOutput.py,v 1.110 2008/03/10 07:50:18 tavis_rudd Exp $
"""Syntax and Output tests.

'''
Syntax and Output tests.
TODO
- #finally
- #filter
- #errorCatcher
- #echo
- #silent
Meta-Data
================================================================================
Author: Tavis Rudd <tavis@damnsimple.com>
Version: $Revision: 1.110 $
Start Date: 2001/03/30
Last Revision Date: $Date: 2008/03/10 07:50:18 $
"""
__author__ = "Tavis Rudd <tavis@damnsimple.com>"
__revision__ = "$Revision: 1.110 $"[11:-2]
'''


##################################################
Expand All @@ -31,6 +23,7 @@
import os
import os.path
import new
import pdb
import warnings

from Cheetah.NameMapper import NotFound
Expand Down

0 comments on commit b7c93f8

Please sign in to comment.