Permalink
Browse files

Better monkeypatch and test.

  • Loading branch information...
1 parent 7810633 commit a52b9e8c752910d98e3a06bf67ce5a176927a595 @jsocol jsocol committed Nov 30, 2012
Showing with 6 additions and 2 deletions.
  1. +2 −1 .travis.yml
  2. +1 −1 jingo/monkey.py
  3. +3 −0 jingo/tests/test_monkey.py
View
@@ -5,7 +5,8 @@ python:
env:
- DJANGO_VERSION=1.3.4
- DJANGO_VERSION=1.4.2
+ - DJANGO_VERSION=1.5b1
install:
- - pip install -q django==$DJANGO_VERSION --use-mirrors
+ - pip install -qe git+git://github.com/django/django.git@${DJANGO_VERSION}#egg=django
- pip install -q -r requirements.txt --use-mirrors
script: fab test
View
@@ -44,7 +44,7 @@ def __html__(self):
Allows interoperability with other template engines.
"""
- return self
+ return unicode(self)
# Django uses StrAndUnicode for classes like Form, BoundField, Widget which
@@ -22,3 +22,6 @@ def test_monkey_patch():
jingo.monkey.patch()
eq_(html, render(t, context))
+
+ s = unicode(form['email'])
+ eq_(s, render('{{ form.email }}', {'form': form}))

0 comments on commit a52b9e8

Please sign in to comment.