summaryrefslogtreecommitdiff
path: root/tests/test_discovery_sample2/tests.py
diff options
context:
space:
mode:
authorwrwrwr <git@wr.waw.pl>2014-11-22 17:59:05 +0100
committerTim Graham <timograham@gmail.com>2014-11-24 19:24:11 -0500
commite22c64dfc0230134c0e9d9ae1d9a5c1589fc8b6e (patch)
tree392a0fda9c438eeb3d2c48c3130c149d3db63d3f /tests/test_discovery_sample2/tests.py
parentca801b8c8f7022cd9334a89ac9ae03f586650234 (diff)
Fixed #23742 -- Added an option to reverse tests order.
This is useful for debugging side effects affecting tests that are usually executed before a given test. Full suite and pair tests sort cases more or less deterministically, thus some test cross-dependencies are easier to reveal by reversing the order. Thanks Preston Timmons for the review.
Diffstat (limited to 'tests/test_discovery_sample2/tests.py')
-rw-r--r--tests/test_discovery_sample2/tests.py56
1 files changed, 53 insertions, 3 deletions
diff --git a/tests/test_discovery_sample2/tests.py b/tests/test_discovery_sample2/tests.py
index 232054a9f1..ac3e9daba0 100644
--- a/tests/test_discovery_sample2/tests.py
+++ b/tests/test_discovery_sample2/tests.py
@@ -1,7 +1,57 @@
-from django.test import TestCase
+from unittest import TestCase
+from django.test import SimpleTestCase, TestCase as DjangoTestCase
-class Test(TestCase):
- def test_sample(self):
+class DjangoCase1(DjangoTestCase):
+
+ def test_1(self):
+ pass
+
+ def test_2(self):
+ pass
+
+
+class DjangoCase2(DjangoTestCase):
+
+ def test_1(self):
+ pass
+
+ def test_2(self):
+ pass
+
+
+class SimpleCase1(SimpleTestCase):
+
+ def test_1(self):
+ pass
+
+ def test_2(self):
+ pass
+
+
+class SimpleCase2(SimpleTestCase):
+
+ def test_1(self):
+ pass
+
+ def test_2(self):
+ pass
+
+
+class UnittestCase1(TestCase):
+
+ def test_1(self):
+ pass
+
+ def test_2(self):
+ pass
+
+
+class UnittestCase2(TestCase):
+
+ def test_1(self):
+ pass
+
+ def test_2(self):
pass