diff --git a/tests/fixtures_regress/fixtures/special-article.json b/tests/fixtures_regress/fixtures/special-article.json
new file mode 100644
index 0000000..435ceb7
|
-
|
+
|
|
| | 1 | [ |
| | 2 | { |
| | 3 | "pk": 1, |
| | 4 | "model": "fixtures_regress.specialarticle", |
| | 5 | "fields": { |
| | 6 | "title": "Article Title 1", |
| | 7 | "channels": [] |
| | 8 | } |
| | 9 | } |
| | 10 | ] |
diff --git a/tests/fixtures_regress/models.py b/tests/fixtures_regress/models.py
index 9909672..ab4fb87 100644
|
a
|
b
|
class Article(models.Model):
|
| 70 | 70 | ordering = ('id',) |
| 71 | 71 | |
| 72 | 72 | |
| | 73 | # Subclass of a model with a ManyToManyField for test_ticket_20820 |
| | 74 | class SpecialArticle(Article): |
| | 75 | pass |
| | 76 | |
| | 77 | |
| 73 | 78 | # Models to regression test #11428 |
| 74 | 79 | @python_2_unicode_compatible |
| 75 | 80 | class Widget(models.Model): |
diff --git a/tests/fixtures_regress/tests.py b/tests/fixtures_regress/tests.py
index f917b21..e2985d3 100644
|
a
|
b
|
class TestFixtures(TestCase):
|
| 444 | 444 | self.assertTrue("No fixture 'this_fixture_doesnt_exist' in" in |
| 445 | 445 | force_text(stdout_output.getvalue())) |
| 446 | 446 | |
| | 447 | def test_ticket_20820(self): |
| | 448 | """ |
| | 449 | Regression for ticket #20820 -- loaddata on a model that inherits |
| | 450 | from a model with a M2M shouldn't blow up. |
| | 451 | """ |
| | 452 | management.call_command( |
| | 453 | 'loaddata', |
| | 454 | 'special-article.json', |
| | 455 | verbosity=0, |
| | 456 | ) |
| | 457 | |
| 447 | 458 | |
| 448 | 459 | class NaturalKeyFixtureTests(TestCase): |
| 449 | 460 | |