I can load the fixture file in my django application using loaddata:
manage.py loaddata palamut
The palamut.yaml element is located in the palamut/fixtures/ directory
I have a unit test module service_tests.py in palamut/tests/ . Its content is here:
import unittest from palamut.models import * from palamut.service import * from palamut.pforms import * class ServiceTest(unittest.TestCase): fixtures = ['palamut.yaml'] def test_convert_vensim(self): game_definition = GameDefinition.objects.get(pk=1)
This unit test gives the following error:
DoesNotExist: GameDefinition matching query does not exist.
I debugged the script and found out that the device is not loaded in the unit test module.
Do you have any suggestions about the reason for this behavior?
By the way, test logs do not contain anything related to the loading of the device.
source share