On 11/20/07, michel bruavics <[EMAIL PROTECTED]> wrote:
>
> Hi djangos,
>
> I check out the django.test.client and want to load a fixture file
> called "myfixture.xml".
>
> I added in my project setting a folder (called fixtures):
> FIXTURE_DIRS = ('/workspace/project/fixtures/')
>
> myfixture.xml is inside of the folder fixtures.
>
> now I try to load the fixture in my tests.py:
>
> class TestSurfer(unittest.TestCase):
>     fixtures = ['myfixture.xml']
> ....
>
> But it doesn't load the fixture.
> I try other names, other places but nothing works for me. I only can
> load a file when it's named "initial_data.xml".

You need to use django.test.TestCase, not unittest.TestCase. The
latter knows nothing about fixtures. :)

Joseph

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to