hi,
I'm having a working django application. I want to see the values of
my variables when I'm executing my code. something like JUnits
containertest for java.
I'm tried to test a method in my views.py code. The method is called
generate_html( ). when i write a test class like:
--------------------------------------
import views
generate_html(123)
-------------------------------------
(the number 123 is just a number i want to display. )
I want to put a breakpoint at the generate_html i get and run my test
but:
Traceback (most recent call last):
File "/Users/eenpint/Documents/workspace/projects/probis/offerte/
tomtestclass.py", line 2, in <module>
import views
File "/Users/eenpint/Documents/workspace/projects/probis/offerte/
views.py", line 4, in <module>
from django.http import HttpResponse
ImportError: No module named django.http
so he doesn't know the django.http import that i use in the views
class. Why does he knows this when i run my server with the "python
manage.py runserver" -command. but he does not know it when i try to
run my test.
so i have two questions:
- how can i let my test work
- perhaps somebody knows a better way to test my application
thanks in advance,
tom
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---