~widelands-dev/widelands-website/django_staticfiles

« back to all changes in this revision

Viewing changes to wlwebchat/tests.py

  • Committer: franku
  • Date: 2016-12-13 18:28:51 UTC
  • mto: This revision was merged to the branch mainline in revision 443.
  • Revision ID: somal@arcor.de-20161213182851-bo5ebf8pdvw5beua
run the script

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
"""
2
 
This file demonstrates two different styles of tests (one doctest and one
 
1
"""This file demonstrates two different styles of tests (one doctest and one
3
2
unittest). These will both pass when you run "manage.py test".
4
3
 
5
4
Replace these with more appropriate tests for your application.
 
5
 
6
6
"""
7
7
 
8
8
from django.test import TestCase
9
9
 
 
10
 
10
11
class SimpleTest(TestCase):
 
12
 
11
13
    def test_basic_addition(self):
12
14
        """
13
15
        Tests that 1 + 1 always equals 2.
14
16
        """
15
17
        self.failUnlessEqual(1 + 1, 2)
16
18
 
17
 
__test__ = {"doctest": """
 
19
__test__ = {'doctest': """
18
20
Another way to test that 1 + 1 is equal to 2.
19
21
 
20
22
>>> 1 + 1 == 2
21
23
True
22
24
"""}
23