Ticket #27419: tests.py
File tests.py, 428 bytes (added by , 8 years ago) |
---|
Line | |
---|---|
1 | from django.test import TestCase |
2 | |
3 | from .models import * |
4 | |
5 | class TestFoo(TestCase): |
6 | |
7 | def test(self): |
8 | parent = Foo(a="parent_a", b="parent_b") |
9 | parent.save() |
10 | foo = Foo(a="1a", b="1b", parent=parent) |
11 | foo.save() |
12 | |
13 | class TestBar(TestCase): |
14 | |
15 | def test(self): |
16 | parent = Bar(a="parent_a", b="parent_b") |
17 | parent.save() |
18 | bar = Bar(a="1a", b="1b", parent=parent) |
19 | bar.save() |