#32756: Inconsistent TestCase results with fixtures
---------------------------------------------+------------------------
Reporter: Alexandr Bezenkov | Owner: nobody
Type: Uncategorized | Status: new
Component: Testing framework | Version: 3.2
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
---------------------------------------------+------------------------
I've created a TestCase for one of my apps which uses fixtures:
{{{
from django.test.testcases import TestCase
class EmployeesTestCase(TestCase):
fixtures = [
'capps/accounts/fixtures/tests',
'capps/locations/fixtures/tests',
'capps/companies/fixtures/tests',
'employees/fixtures/tests',
]
...
}}}
Everything is fine except one thing: sometimes testcase fails with error
**json.decoder.JSONDecodeError: Problem installing fixture**.
Here's the link to the video demonstrating the issue
https://youtu.be/GqMarU0_XW0
Tried with both Django 3.2.2 and 3.2.3, with python 3.8.9 and 3.9.5, with
PostgreSQL 13 and SQLite 3.
All fixtures were created by {{{python manage.py dumpdata }}}.
This is the case for all apps in my project, it either loads data, or
fails to do so without any change from my side.
Can someone please explain what kind of black magic is this?
--
Ticket URL: <https://code.djangoproject.com/ticket/32756>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/053.1920af6db0bf1dd252cac469a5716bab%40djangoproject.com.