mirror of
https://github.com/django/django.git
synced 2025-10-23 21:59:11 +00:00
Added tests for various __repr__() methods.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
from django.template.defaulttags import IfEqualNode
|
||||
from django.test import SimpleTestCase
|
||||
|
||||
from ..utils import setup
|
||||
@@ -215,3 +216,9 @@ class IfNotEqualTagTests(SimpleTestCase):
|
||||
def test_ifnotequal04(self):
|
||||
output = self.engine.render_to_string('ifnotequal04', {'a': 1, 'b': 1})
|
||||
self.assertEqual(output, 'no')
|
||||
|
||||
|
||||
class IfEqualTests(SimpleTestCase):
|
||||
def test_repr(self):
|
||||
node = IfEqualNode(var1='a', var2='b', nodelist_true=[], nodelist_false=[], negate=False)
|
||||
self.assertEqual(repr(node), '<IfEqualNode>')
|
||||
|
||||
Reference in New Issue
Block a user