Commit f5b37f72 by Chris Jerdonek

Removed the word "view" from the Complex example.

parent dec5054d
class ComplexView(object):
class Complex(object):
def header(self):
return "Colors"
......
......@@ -3,7 +3,7 @@ import unittest
import pystache
from pystache import Renderer
from examples.nested_context import NestedContext
from examples.complex_view import ComplexView
from examples.complex import Complex
from examples.lambdas import Lambdas
from examples.template_partial import TemplatePartial
from examples.simple import Simple
......@@ -20,7 +20,7 @@ class TestSimple(unittest.TestCase, AssertStringMixin):
def test_looping_and_negation_context(self):
template = '{{#item}}{{header}}: {{name}} {{/item}}{{^item}} Shouldnt see me{{/item}}'
context = ComplexView()
context = Complex()
renderer = Renderer()
expected = renderer.render(template, context)
......
......@@ -10,7 +10,7 @@ import sys
import unittest
from examples.simple import Simple
from examples.complex_view import ComplexView
from examples.complex import Complex
from examples.lambdas import Lambdas
from examples.inverted import Inverted, InvertedLists
from pystache import TemplateSpec as Template
......@@ -84,8 +84,8 @@ class ViewTestCase(unittest.TestCase, AssertStringMixin):
def test_complex(self):
renderer = Renderer()
expected = renderer.render(ComplexView())
self.assertEquals(expected, """\
expected = renderer.render(Complex())
self.assertString(expected, u"""\
<h1>Colors</h1>
<ul>
<li><strong>red</strong></li>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment